electron-updater
Advanced tools
Comparing version 5.0.0-alpha.3 to 5.0.0-alpha.4
@@ -106,3 +106,3 @@ /// <reference types="node" /> | ||
*/ | ||
checkForUpdates(): Promise<UpdateCheckResult>; | ||
checkForUpdates(): Promise<UpdateCheckResult | null>; | ||
isUpdaterActive(): boolean; | ||
@@ -109,0 +109,0 @@ checkForUpdatesAndNotify(downloadNotification?: DownloadNotification): Promise<UpdateCheckResult | null>; |
@@ -190,2 +190,5 @@ "use strict"; | ||
checkForUpdates() { | ||
if (!this.isUpdaterActive()) { | ||
return Promise.resolve(null); | ||
} | ||
let checkForUpdatesPromise = this.checkForUpdatesPromise; | ||
@@ -220,8 +223,4 @@ if (checkForUpdatesPromise != null) { | ||
checkForUpdatesAndNotify(downloadNotification) { | ||
if (!this.isUpdaterActive()) { | ||
return Promise.resolve(null); | ||
} | ||
return this.checkForUpdates().then(it => { | ||
const downloadPromise = it.downloadPromise; | ||
if (downloadPromise == null) { | ||
if (!(it === null || it === void 0 ? void 0 : it.downloadPromise)) { | ||
if (this._logger.debug != null) { | ||
@@ -232,3 +231,3 @@ this._logger.debug("checkForUpdatesAndNotify called, downloadPromise is null"); | ||
} | ||
void downloadPromise.then(() => { | ||
void it.downloadPromise.then(() => { | ||
const notificationContent = AppUpdater.formatDownloadNotification(it.updateInfo.version, this.app.name, downloadNotification); | ||
@@ -235,0 +234,0 @@ new (require("electron").Notification)(notificationContent).show(); |
{ | ||
"name": "electron-updater", | ||
"version": "5.0.0-alpha.3", | ||
"version": "5.0.0-alpha.4", | ||
"description": "Cross platform updater for electron applications", | ||
@@ -5,0 +5,0 @@ "main": "out/main.js", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
416101
3791