diff --git a/package-lock.json b/package-lock.json index d83a108..022b1ca 100644 --- a/package-lock.json +++ b/package-lock.json @@ -15,6 +15,8 @@ "electron-store": "^8.1.0", "monaco-editor": "^0.45.0", "pinia": "^2.1.7", + "pinia-plugin-persistedstate": "^3.2.1", + "update-electron-app": "^3.0.0", "vue": "^3.4.13", "vue-i18n": "^9.9.0", "vue-router": "^4.2.5" @@ -7541,6 +7543,14 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/github-url-to-object": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/github-url-to-object/-/github-url-to-object-4.0.6.tgz", + "integrity": "sha512-NaqbYHMUAlPcmWFdrAB7bcxrNIiiJWJe8s/2+iOc9vlcHlwHqSGrPk+Yi3nu6ebTwgsZEa7igz+NH2vEq3gYwQ==", + "dependencies": { + "is-url": "^1.1.0" + } + }, "node_modules/glob": { "version": "7.2.3", "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", @@ -8297,6 +8307,11 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/is-url": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/is-url/-/is-url-1.2.4.tgz", + "integrity": "sha512-ITvGim8FhRiYe4IQ5uHSkj7pVaPDrCTkNd3yq3cV7iZAcJdHTUMPMEHcqSOy9xZ9qFenQCvi+2wjH9a1nXqHww==" + }, "node_modules/is-windows": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/is-windows/-/is-windows-1.0.2.tgz", @@ -10511,6 +10526,14 @@ } } }, + "node_modules/pinia-plugin-persistedstate": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/pinia-plugin-persistedstate/-/pinia-plugin-persistedstate-3.2.1.tgz", + "integrity": "sha512-MK++8LRUsGF7r45PjBFES82ISnPzyO6IZx3CH5vyPseFLZCk1g2kgx6l/nW8pEBKxxd4do0P6bJw+mUSZIEZUQ==", + "peerDependencies": { + "pinia": "^2.0.0" + } + }, "node_modules/pinia/node_modules/vue-demi": { "version": "0.14.5", "resolved": "https://registry.npmjs.org/vue-demi/-/vue-demi-0.14.5.tgz", @@ -12618,6 +12641,16 @@ "browserslist": ">= 4.21.0" } }, + "node_modules/update-electron-app": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/update-electron-app/-/update-electron-app-3.0.0.tgz", + "integrity": "sha512-Ccs46fgUEcMpSRPMNw82DFMux2MGi5tkKkEpV723JmtPNI3qAtxvTeiYkKczN2/LehA3U7JGrGr4MhraxGdRTw==", + "dependencies": { + "github-url-to-object": "^4.0.4", + "is-url": "^1.2.4", + "ms": "^2.1.1" + } + }, "node_modules/uri-js": { "version": "4.4.1", "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", diff --git a/src/electron/main.ts b/src/electron/main.ts index 3bc8108..6ee615d 100644 --- a/src/electron/main.ts +++ b/src/electron/main.ts @@ -136,7 +136,10 @@ app.on('window-all-closed', () => { app.quit(); } }); - -autoUpdater.setFeedURL({ - url: `https://dockit-eta.vercel.app//update/${process.platform}/${app.getVersion()}`, -}); +try { + autoUpdater.setFeedURL({ + url: `https://dockit-eta.vercel.app//update/${process.platform}/${app.getVersion()}`, + }); +} catch (err) { + /* empty */ +}