fix variable problems (#3304)

related to #3302

- fix MM_PORT variable not used in electron
- fix to allow full path for MM_CONFIG_FILE variable
This commit is contained in:
Karsten Hassel
2023-12-28 21:58:31 +01:00
committed by GitHub
parent aad3eefc62
commit a927eb20d9
3 changed files with 4 additions and 2 deletions

View File

@@ -79,7 +79,8 @@ function createWindow () {
}
let address = (config.address === void 0) | (config.address === "") | (config.address === "0.0.0.0") ? (config.address = "localhost") : config.address;
mainWindow.loadURL(`${prefix}${address}:${config.port}`);
const port = process.env.MM_PORT || config.port;
mainWindow.loadURL(`${prefix}${address}:${port}`);
// Open the DevTools if run with "npm start dev"
if (process.argv.includes("dev")) {