Skip to content

Commit

Permalink
skip attempt to install updates at launch when update checks are disa…
Browse files Browse the repository at this point in the history
…bled

Signed-off-by: Jyrki Gadinger <[email protected]>
  • Loading branch information
nilsding committed Feb 10, 2025
1 parent 8f6ed83 commit 8bb0e9e
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/gui/updater/ocupdater.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -496,6 +496,13 @@ bool NSISUpdater::handleStartup()
{
ConfigFile cfg;
QSettings settings(cfg.configFile(), QSettings::IniFormat);

// no need to try to install a previously fetched update when the user doesn't want automated updates
if (cfg.skipUpdateCheck() || !cfg.autoUpdateCheck()) {
qCInfo(lcUpdater) << "Skipping installation of update due to config settings";
return false;
}

QString updateFileName = settings.value(updateAvailableC).toString();
// has the previous run downloaded an update?
if (!updateFileName.isEmpty() && QFile(updateFileName).exists()) {
Expand Down

0 comments on commit 8bb0e9e

Please sign in to comment.