mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-30 06:14:01 +03:00
NSISUpdater: Fix logic to invoke updater on non-explicit start
This commit is contained in:
parent
cf7b77e2bf
commit
19e7c4f66f
1 changed files with 6 additions and 6 deletions
|
@ -333,7 +333,7 @@ NSISUpdater::UpdateState NSISUpdater::updateStateOnStart()
|
|||
// has the previous run downloaded an update?
|
||||
if (!updateFileName.isEmpty() && QFile(updateFileName).exists()) {
|
||||
// did it try to execute the update?
|
||||
if (settings.value(autoUpdateAttemptedC).toBool()) {
|
||||
if (settings.value(autoUpdateAttemptedC, false).toBool()) {
|
||||
// clean up
|
||||
settings.remove(autoUpdateAttemptedC);
|
||||
settings.remove(updateAvailableC);
|
||||
|
@ -351,13 +351,13 @@ NSISUpdater::UpdateState NSISUpdater::updateStateOnStart()
|
|||
settings.remove(updateTargetVersionC);
|
||||
return UpdateFailed;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (!settings.contains(autoUpdateFailedVersionC)) {
|
||||
return UpdateAvailable;
|
||||
} else {
|
||||
if (!settings.contains(autoUpdateFailedVersionC)) {
|
||||
return UpdateAvailable;
|
||||
}
|
||||
}
|
||||
}
|
||||
return NoUpdate;
|
||||
return NoUpdate;
|
||||
}
|
||||
|
||||
bool NSISUpdater::handleStartup()
|
||||
|
|
Loading…
Reference in a new issue