From 5b4db16b64de6b22e405c4c2a8a338393f04d0de Mon Sep 17 00:00:00 2001 From: Agampreet Singh <68941022+agam778@users.noreply.github.com> Date: Sun, 11 Jun 2023 21:49:09 +0530 Subject: [PATCH] Do not log if internet is connected --- app/main.js | 30 +++++++++++++----------------- 1 file changed, 13 insertions(+), 17 deletions(-) diff --git a/app/main.js b/app/main.js index a2cdba1..3207c97 100644 --- a/app/main.js +++ b/app/main.js @@ -328,24 +328,20 @@ app.on("activate", () => { }); app.on("ready", function () { - checkInternetConnected() - .then(() => { - console.log("You are connected to the internet!"); - }) - .catch(() => { - const options = { - type: "warning", - buttons: ["Ok"], - defaultId: 2, - title: "Warning", - message: "You appear to be offline!", - detail: - "Please check your Internet Connectivity. This app cannot run without an Internet Connection!", - }; - dialog.showMessageBox(null, options, (response) => { - console.log(response); - }); + checkInternetConnected().catch(() => { + const options = { + type: "warning", + buttons: ["Ok"], + defaultId: 2, + title: "Warning", + message: "You appear to be offline!", + detail: + "Please check your Internet Connectivity. This app cannot run without an Internet Connection!", + }; + dialog.showMessageBox(null, options, (response) => { + console.log(response); }); + }); autoUpdater.checkForUpdatesAndNotify(); if (getValue("discordrpcstatus") === "true") { loginToRPC();