From 47932ccfd4f184fc166232e965955950ebeee503 Mon Sep 17 00:00:00 2001 From: thearturca Date: Fri, 15 Jan 2021 13:03:57 +0500 Subject: [PATCH] fixed command order for setup --- src/main.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/main.js b/src/main.js index 13adb96..32ec4c2 100644 --- a/src/main.js +++ b/src/main.js @@ -4,6 +4,8 @@ const path = require('path'); const { app, BrowserWindow, Menu, Tray, ipcMain } = require('electron'); const keytar = require('keytar') +if (require('electron-squirrel-startup')) return app.quit(); + const appName = '200iqbot'; if (!fs.existsSync(path.join(app.getPath('documents'), appName))){ fs.mkdirSync(path.join(app.getPath('documents'), appName)); @@ -22,9 +24,6 @@ if (!fs.existsSync(dirDB)){ const axios = require('axios'); -if (require('electron-squirrel-startup')) return app.quit(); -console.log(app.getPath('documents')); - const gotTheLock = app.requestSingleInstanceLock() if (!gotTheLock) {