fix: handle potential missing close event property (#46605)
fix: handle missing close event property
This commit is contained in:
parent
a9b2ec514b
commit
62b5b5f99d
1 changed files with 1 additions and 1 deletions
|
@ -54,7 +54,7 @@ BrowserWindow.prototype._init = function (this: BWT) {
|
|||
});
|
||||
this.on('close', (event) => {
|
||||
queueMicrotask(() => {
|
||||
if (!unresponsiveEvent && !event.defaultPrevented) {
|
||||
if (!unresponsiveEvent && !event?.defaultPrevented) {
|
||||
unresponsiveEvent = setTimeout(emitUnresponsiveEvent, 5000);
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue