summaryrefslogtreecommitdiffhomepage
path: root/gui/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'gui/src/main')
-rw-r--r--gui/src/main/index.ts24
1 files changed, 6 insertions, 18 deletions
diff --git a/gui/src/main/index.ts b/gui/src/main/index.ts
index f0cd89a52d..159c8b7dfa 100644
--- a/gui/src/main/index.ts
+++ b/gui/src/main/index.ts
@@ -1,15 +1,5 @@
import { execFile } from 'child_process';
-import {
- app,
- BrowserWindow,
- ipcMain,
- Menu,
- nativeImage,
- screen,
- session,
- shell,
- Tray,
-} from 'electron';
+import { app, BrowserWindow, Menu, nativeImage, screen, session, shell, Tray } from 'electron';
import log from 'electron-log';
import mkdirp from 'mkdirp';
import moment from 'moment';
@@ -530,6 +520,11 @@ class ApplicationMain {
if (this.windowController) {
IpcMainEventChannel.daemonConnected.notify(this.windowController.webContents);
}
+
+ // show window when account is not set
+ if (!this.settings.accountToken) {
+ this.windowController?.show();
+ }
};
private onDaemonDisconnected = (error?: Error) => {
@@ -1090,13 +1085,6 @@ class ApplicationMain {
}
});
- ipcMain.on('show-window', () => {
- const windowController = this.windowController;
- if (windowController) {
- windowController.show();
- }
- });
-
IpcMainEventChannel.problemReport.handleCollectLogs((toRedact) => {
const reportPath = path.join(app.getPath('temp'), uuid.v4() + '.log');
const executable = resolveBin('mullvad-problem-report');