Prevent re-downloading update that is already downloaded (#5781)

This commit is contained in:
Janne Savolainen authored and GitHub committed 2022-07-06 08:06:59 -04:00
1 parent 4d99a46dfe
commit 5ac33a6070
5 files changed
+355 -1

No files matched your search

@@ -49,6 +49,16 @@ const processCheckingForUpdatesInjectable = getInjectable({
const { version, actualUpdateChannel } = result;
const previouslyDiscovered = discoveredVersionState.value.get();
if (version === previouslyDiscovered?.version) {
runInAction(() => {
checkingForUpdatesState.set(false);
});
return;
}
emitEvent({
name: "app",
action: "update-was-discovered",