Update browserWindows.js

This commit is contained in:
rafael-aero
2021-08-23 15:30:47 +02:00
parent 9a680a41ac
commit fdbf7187b9

View File

@@ -202,6 +202,15 @@ module.exports = (socket, app) => {
proxyToCredentialsMap[options.proxy] = options.proxyCredentials;
}
window.on('ready-to-show', () => {
try {
window.id;
}
catch (error) {
if (error.message === 'Object has been destroyed') {
return;
}
}
if (readyToShowWindowsIds.includes(window.id)) {
readyToShowWindowsIds = readyToShowWindowsIds.filter(value => value !== window.id);
}