aboutsummaryrefslogtreecommitdiff
path: root/src/utils.js
diff options
context:
space:
mode:
authorAlystrasz <contact@remyraes.com>2022-08-09 10:59:53 +0200
committerAlystrasz <contact@remyraes.com>2022-08-09 10:59:53 +0200
commit3d9a315f31be7345b0d2ebf3a8beba55f547749b (patch)
treedb39c3f38ef1fcbcf6a0e2444470f32fc9058b6a /src/utils.js
parent58b3ad7bab848f608d5b5f4f319de1da519eacd0 (diff)
parent5106d9ed409a3cc91a7755f961fab1bf91d8b7fb (diff)
downloadViper-3d9a315f31be7345b0d2ebf3a8beba55f547749b.tar.gz
Viper-3d9a315f31be7345b0d2ebf3a8beba55f547749b.zip
Merge branch 'main' into feat/ci-builds
Diffstat (limited to 'src/utils.js')
-rw-r--r--src/utils.js5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/utils.js b/src/utils.js
index e8d14cc..31a2b28 100644
--- a/src/utils.js
+++ b/src/utils.js
@@ -155,6 +155,7 @@ function handleNorthstarUpdating() {
async function _checkForUpdates() {
let localVersion = getNSVersion();
let distantVersion = await requests.getLatestNsVersion();
+ if (distantVersion == false) { return; }
console.log(lang("cli.autoupdates.checking"));
// Checks if NS is outdated
@@ -361,6 +362,10 @@ async function update() {
const latestAvailableVersion = await requests.getLatestNsVersion();
console.log(latestAvailableVersion)
+ if (latestAvailableVersion == false) {
+ ipcMain.emit("ns-update-event", "cli.update.noInternet");
+ return;
+ }
// Makes sure it is not already the latest version
if (version === latestAvailableVersion) {