From f3852c57fc6aba00bf77c47ae3e3443f05aae284 Mon Sep 17 00:00:00 2001 From: Kevin Sawicki Date: Wed, 11 Jan 2017 17:07:05 -0800 Subject: [PATCH] Use empty string for comparison --- lib/renderer/window-setup.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/renderer/window-setup.js b/lib/renderer/window-setup.js index 530907856efa..1e1d1792c531 100644 --- a/lib/renderer/window-setup.js +++ b/lib/renderer/window-setup.js @@ -80,7 +80,7 @@ module.exports = (ipcRenderer, guestInstanceId, openerId, hiddenPage) => { // Make the browser window or guest view emit "new-window" event. window.open = function (url, frameName, features) { - if (url != null && url.length > 0) { + if (url != null && url !== '') { url = resolveURL(url) } const guestId = ipcRenderer.sendSync('ELECTRON_GUEST_WINDOW_MANAGER_WINDOW_OPEN', url, frameName, features)