Do not show window if launched as hidden

This commit is contained in:
Josh Perez 2021-12-06 12:19:47 -05:00 committed by GitHub
parent 86937a1734
commit 69edaeabfb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 1 deletions

View File

@ -699,7 +699,10 @@ async function createWindow() {
return;
}
if (!startInTray) {
const shouldShowWindow =
!app.getLoginItemSettings().wasOpenedAsHidden && !startInTray;
if (shouldShowWindow) {
getLogger().info('showing main window');
mainWindow.show();
}