From 866734b84fb3280311a7dd83531b54c7a0aafbe5 Mon Sep 17 00:00:00 2001 From: Sergey Kintsel Date: Fri, 24 Nov 2023 15:37:48 +0000 Subject: [PATCH] Add private token for update fetching --- public/electron.js | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/public/electron.js b/public/electron.js index 715dfcef41..b0ef0e203f 100644 --- a/public/electron.js +++ b/public/electron.js @@ -3,19 +3,26 @@ const { app, BrowserWindow, shell } = require("electron"); const path = require("path"); const url = require("url"); const { autoUpdater } = require("electron-updater"); +const process = require("process"); // Keep a global reference of the window object, if you don't, the window will // be closed automatically when the JavaScript object is garbage collected. let mainWindow; let deeplinkURL; +process.env["GH_TOKEN"] = + "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"; + // Assure single instance if (!app.requestSingleInstanceLock()) { app.quit(); return; } - -autoUpdater.checkForUpdatesAndNotify(); +try { + autoUpdater.checkForUpdatesAndNotify(); +} catch (e) { + console.log(e); +} // Enable experimental to activate Web USB support app.commandLine.appendSwitch("enable-experimental-web-platform-features", true);