From eea6be459d5dbfafb9a5285046282c25c4697242 Mon Sep 17 00:00:00 2001 From: Taloth Saldono Date: Sun, 14 Mar 2021 20:24:08 +0100 Subject: [PATCH] Fixed post-install update check not running --- .../Update/InstallUpdateService.cs | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/src/NzbDrone.Core/Update/InstallUpdateService.cs b/src/NzbDrone.Core/Update/InstallUpdateService.cs index 6dd2934ea..080d46efd 100644 --- a/src/NzbDrone.Core/Update/InstallUpdateService.cs +++ b/src/NzbDrone.Core/Update/InstallUpdateService.cs @@ -293,14 +293,6 @@ namespace NzbDrone.Core.Update try { - // Don't do a prestartup update check unless BuiltIn update is enabled - if (_configFileProvider.UpdateAutomatically || - _configFileProvider.UpdateMechanism != UpdateMechanism.BuiltIn || - _deploymentInfoProvider.IsExternalUpdateMechanism) - { - return; - } - var updateMarker = Path.Combine(_appFolderInfo.AppDataFolder, "update_required"); if (!_diskProvider.FileExists(updateMarker)) { @@ -309,6 +301,15 @@ namespace NzbDrone.Core.Update _logger.Debug("Post-install update check requested"); + // Don't do a prestartup update check unless BuiltIn update is enabled + if (!_configFileProvider.UpdateAutomatically || + _configFileProvider.UpdateMechanism != UpdateMechanism.BuiltIn || + _deploymentInfoProvider.IsExternalUpdateMechanism) + { + _logger.Debug("Built-in updater disabled, skipping post-install update check"); + return; + } + var latestAvailable = _checkUpdateService.AvailableUpdate(); if (latestAvailable == null) {