From a29564c42d48918477a4f439b95b90c5c1d92f1d Mon Sep 17 00:00:00 2001 From: Oj Date: Fri, 10 Dec 2021 17:17:00 +0000 Subject: [PATCH] [Paths] Tweak resources path, set var instead of making each func --- src/paths.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/paths.js b/src/paths.js index b239a1f..ff41034 100644 --- a/src/paths.js +++ b/src/paths.js @@ -12,12 +12,12 @@ const exeDir = dirname(app.getPath('exe')); const installPath = /^app-[0-9]+\.[0-9]+\.[0-9]+/.test(basename(exeDir)) ? join(exeDir, '..') : null; const moduleData = buildInfo.newUpdater ? join(userData, 'module_data') : join(userDataVersioned, 'modules'); - +const resourcesPath = join(process.resourcesPath, '..'); // Discord uses path and require.main.filename here because ?? exports.getUserData = () => userData; exports.getUserDataVersioned = () => userDataVersioned; -exports.getResources = () => process.resourcesPath; // Discord uses path and require.main.filename here because ?? +exports.getResources = () => resourcesPath; exports.getModuleDataPath = () => moduleData; exports.getInstallPath = () => installPath;