This commit is contained in:
Jan Prochazka
2022-01-06 08:08:40 +01:00
parent 397fbb9832
commit 283eeb7de5

View File

@@ -205,6 +205,7 @@ function createWindow() {
slashes: true, slashes: true,
}); });
mainWindow.on('close', () => { mainWindow.on('close', () => {
try {
fs.writeFileSync( fs.writeFileSync(
configRootPath, configRootPath,
JSON.stringify({ JSON.stringify({
@@ -213,6 +214,9 @@ function createWindow() {
}), }),
'utf-8' 'utf-8'
); );
} catch (err) {
console.log('Error saving config-root:', err.message);
}
}); });
mainWindow.loadURL(startUrl); mainWindow.loadURL(startUrl);
if (os.platform() == 'linux') { if (os.platform() == 'linux') {