From 52f3607606193399986fa3a25050c712b920b4b4 Mon Sep 17 00:00:00 2001 From: Ben Gotow Date: Thu, 19 May 2016 12:28:29 -0700 Subject: [PATCH] fix(win-launching): Only create hot window when one is used --- src/browser/window-launcher.es6 | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/browser/window-launcher.es6 b/src/browser/window-launcher.es6 index 482a77d00..bf7a8a22e 100644 --- a/src/browser/window-launcher.es6 +++ b/src/browser/window-launcher.es6 @@ -50,7 +50,8 @@ export default class WindowLauncher { if (!this.hotWindow) { this.createHotWindow() } - win = this.hotWindow + win = this.hotWindow; + this.createHotWindow(); const newLoadSettings = Object.assign({}, win.loadSettings(), opts) if (newLoadSettings.windowType === WindowLauncher.EMPTY_WINDOW) { @@ -73,10 +74,6 @@ export default class WindowLauncher { // hide based on the windowOpts win.showWhenLoaded() } - - // Create a new hot window to keep in store for the next time we call - // newWindow() - this.createHotWindow(); return win }