diff --git a/src/background/electronAppPath.js b/src/background/electronAppPath.js index 79ce5fc..8fb307d 100644 --- a/src/background/electronAppPath.js +++ b/src/background/electronAppPath.js @@ -10,6 +10,10 @@ export default (app) => { return `./${app}.exe` } + if(/^win/.test(process.platform) && fs.existsSync(path.dirname(process.execPath) + `/${app}.exe`)) { + return path.dirname(process.execPath) + `/${app}.exe` + } + if (fs.existsSync(fs.realpathSync(__dirname) + `/${app}`)) { return fs.realpathSync(__dirname) + `/${app}` }