From 80faba82340da92a371ad797793b1cfd3f2335f8 Mon Sep 17 00:00:00 2001 From: Feross Aboukhadijeh Date: Fri, 13 May 2016 13:29:25 -0700 Subject: [PATCH] Fix isProduction() detection In the renderer process on OS X, config.IS_PRODUCTION was always true because process.execPath is to "Electron Helper", so the detection regex was being overly specific. --- config.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config.js b/config.js index fc77ff6a..db96cfab 100644 --- a/config.js +++ b/config.js @@ -69,7 +69,7 @@ function isProduction () { return false } if (process.platform === 'darwin') { - return !/\/Electron\.app\/Contents\/MacOS\/Electron$/.test(process.execPath) + return !/\/Electron\.app\//.test(process.execPath) } if (process.platform === 'win32') { return !/\\electron\.exe$/.test(process.execPath)