From ea8cc06bbf3f392a1b9f65812434f54d04fca2e8 Mon Sep 17 00:00:00 2001 From: Alexander Drozdov Date: Sat, 31 Dec 2022 21:19:46 +0200 Subject: [PATCH] fixes missing dir #823 --- main/src/AppTray.ts | 2 +- main/src/host-files/ConfigStore.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/main/src/AppTray.ts b/main/src/AppTray.ts index 4d3f126e..e73e4d15 100644 --- a/main/src/AppTray.ts +++ b/main/src/AppTray.ts @@ -39,7 +39,7 @@ export class AppTray { } }, { - label: 'Open logs folder', + label: 'Open config folder', click: () => { shell.openPath(path.join(app.getPath('userData'), 'apt-data')) } diff --git a/main/src/host-files/ConfigStore.ts b/main/src/host-files/ConfigStore.ts index 427653d1..d30de79d 100644 --- a/main/src/host-files/ConfigStore.ts +++ b/main/src/host-files/ConfigStore.ts @@ -33,6 +33,7 @@ export class ConfigStore { this.isTmpFile = true } try { + await fs.mkdir(path.dirname(this.cfgPath), { recursive: true }) await fs.writeFile(this.cfgPath, contents) } catch { app.exit(1)