From a8f54c25df0519f12e50b0d9ff92d198061e6463 Mon Sep 17 00:00:00 2001 From: Ben Gotow Date: Wed, 18 May 2016 16:08:58 -0700 Subject: [PATCH] fix(win32): Ignore path in argv when --squirrel flag is present --- src/browser/main.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/browser/main.js b/src/browser/main.js index a1840d6de..6b2dde542 100644 --- a/src/browser/main.js +++ b/src/browser/main.js @@ -1,4 +1,5 @@ /* eslint dot-notation: 0 */ +/* eslint global-require: 0 */ global.shellStartTime = Date.now(); const app = require('electron').app; @@ -81,7 +82,7 @@ const parseCommandLine = (argv) => { const pathsToOpen = []; // On Windows and Linux, mailto and file opens are passed as the last argv - if (argv.length > 1) { + if (argv.length > 1 && !argv.join(' ').includes('--squirrel')) { const lastArg = argv[argv.length - 1]; if (lastArg.startsWith('mailto:')) { urlsToOpen.push(lastArg);