mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-08-14 02:26:58 -07:00
Fix auto-updater not working after enabling unless Tautulli was restarted
This commit is contained in:
parent
63e056987a
commit
e6c2133bf5
2 changed files with 5 additions and 5 deletions
|
@ -442,7 +442,7 @@ def initialize_scheduler():
|
|||
pms_update_check_hours = CONFIG.PMS_UPDATE_CHECK_INTERVAL if 1 <= CONFIG.PMS_UPDATE_CHECK_INTERVAL else 24
|
||||
|
||||
schedule_job(versioncheck.check_update, 'Check GitHub for updates',
|
||||
hours=0, minutes=github_minutes, seconds=0, args=(bool(CONFIG.PLEXPY_AUTO_UPDATE), True))
|
||||
hours=0, minutes=github_minutes, seconds=0, args=(True, True))
|
||||
|
||||
backup_hours = CONFIG.BACKUP_INTERVAL if 1 <= CONFIG.BACKUP_INTERVAL <= 24 else 6
|
||||
|
||||
|
|
|
@ -135,8 +135,8 @@ def getVersion():
|
|||
return current_version, 'origin', current_branch
|
||||
|
||||
|
||||
def check_update(auto_update=False, notify=False):
|
||||
check_github(auto_update=auto_update, notify=notify)
|
||||
def check_update(scheduler=False, notify=False):
|
||||
check_github(scheduler=scheduler, notify=notify)
|
||||
|
||||
if not plexpy.CURRENT_VERSION:
|
||||
plexpy.UPDATE_AVAILABLE = None
|
||||
|
@ -159,7 +159,7 @@ def check_update(auto_update=False, notify=False):
|
|||
plexpy.WIN_SYS_TRAY_ICON.update(icon=icon, hover_text=hover_text)
|
||||
|
||||
|
||||
def check_github(auto_update=False, notify=False):
|
||||
def check_github(scheduler=False, notify=False):
|
||||
plexpy.COMMITS_BEHIND = 0
|
||||
|
||||
if plexpy.CONFIG.GIT_TOKEN:
|
||||
|
@ -236,7 +236,7 @@ def check_github(auto_update=False, notify=False):
|
|||
'plexpy_update_commit': plexpy.LATEST_VERSION,
|
||||
'plexpy_update_behind': plexpy.COMMITS_BEHIND})
|
||||
|
||||
if auto_update and not plexpy.DOCKER:
|
||||
if scheduler and plexpy.CONFIG.PLEXPY_AUTO_UPDATE and not plexpy.DOCKER:
|
||||
logger.info('Running automatic update.')
|
||||
plexpy.shutdown(restart=True, update=True)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue