From b8f9bc8d447a0f73fc4918934959df8a1255306b Mon Sep 17 00:00:00 2001 From: Ben Gotow Date: Fri, 9 Nov 2018 12:09:23 -0800 Subject: [PATCH] Properly remove hotwindow reference when window is destroyed --- app/src/browser/window-manager.es6 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/src/browser/window-manager.es6 b/app/src/browser/window-manager.es6 index 784b377da..7ac185a4b 100644 --- a/app/src/browser/window-manager.es6 +++ b/app/src/browser/window-manager.es6 @@ -122,6 +122,9 @@ export default class WindowManager { _didCreateNewWindow = win => { win.browserWindow.on('closed', () => { delete this._windows[win.windowKey]; + if (this.windowLauncher.hotWindow === win) { + this.windowLauncher.hotWindow = null; + } this.quitWinLinuxIfNoWindows(); });