diff --git a/resources/js/helpers.js b/resources/js/helpers.js index f88b65b..1beba4a 100644 --- a/resources/js/helpers.js +++ b/resources/js/helpers.js @@ -59,7 +59,7 @@ async function proxyIsInstalled() { async function openGameFolder() { const config = await getCfg() - const folder = config.gameexe.match(/.*\//g, '')[0] + const folder = config.gameexe.match(/.*\\/g, '')[0] openInExplorer(folder) } diff --git a/resources/js/index.js b/resources/js/index.js index 95a7857..3070a54 100644 --- a/resources/js/index.js +++ b/resources/js/index.js @@ -7,6 +7,7 @@ const createCmdWindow = async (command) => { } const openInExplorer = async (path) => { + console.log(`explorer.exe "${path}"`) createCmdWindow(`explorer.exe "${path}"`) } @@ -391,7 +392,7 @@ async function setGameExe() { const config = await getCfg() // It's an array of selections, so only get the first one - config.gameexe = gameExe[0] + config.gameexe = gameExe[0].replace(/\//g, '\\') Neutralino.storage.setData('config', JSON.stringify(config))