We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 712c2a4 + ddfb4c0 commit b8182deCopy full SHA for b8182de
1 file changed
electron/main/index.ts
@@ -1282,9 +1282,9 @@ async function createWindow() {
1282
}
1283
})();
1284
`).then(needsReload => {
1285
- if (needsReload) {
+ if (needsReload && win && !win.isDestroyed()) {
1286
log.info('Reloading window after localStorage update');
1287
- win!.reload();
+ win.reload();
1288
1289
}).catch(err => {
1290
log.error('Failed to inject script:', err);
0 commit comments