File tree Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -28,7 +28,19 @@ function installUpdate(): void {
28
28
29
29
function pollForUpdates ( ) : void {
30
30
try {
31
- autoUpdater . checkForUpdates ( ) ;
31
+ // If we've already got a new update downloaded, then stop
32
+ // trying to check for new ones, as according to the doc
33
+ // at https://github.com/electron/electron/blob/main/docs/api/auto-updater.md#autoupdatercheckforupdates
34
+ // we'll just keep re-downloading the same update.
35
+ // As a hunch, this might also be causing
36
+ // https://github.com/vector-im/element-web/issues/12433
37
+ // due to the update checks colliding with the pending install
38
+ // somehow
39
+ if ( ! latestUpdateDownloaded ) {
40
+ autoUpdater . checkForUpdates ( ) ;
41
+ } else {
42
+ console . log ( "Skipping update check as download already present" ) ;
43
+ }
32
44
} catch ( e ) {
33
45
console . log ( 'Couldn\'t check for update' , e ) ;
34
46
}
You can’t perform that action at this time.
0 commit comments