mirror of
https://github.com/clinton-hall/nzbToMedia.git
synced 2025-08-14 10:36:52 -07:00
Fix version check conditional
This commit is contained in:
parent
750c203216
commit
bd4c830313
1 changed files with 11 additions and 13 deletions
|
@ -373,19 +373,17 @@ def configure_updates():
|
|||
version_checker = version_check.CheckVersion()
|
||||
|
||||
# Check for updates via GitHUB
|
||||
if version_checker.check_for_new_version():
|
||||
if AUTO_UPDATE == 1:
|
||||
logger.info('Auto-Updating nzbToMedia, Please wait ...')
|
||||
updated = version_checker.update()
|
||||
if updated:
|
||||
# restart nzbToMedia
|
||||
try:
|
||||
del MYAPP
|
||||
except Exception:
|
||||
pass
|
||||
restart()
|
||||
else:
|
||||
logger.error('Update wasn\'t successful, not restarting. Check your log for more information.')
|
||||
if version_checker.check_for_new_version() and AUTO_UPDATE:
|
||||
logger.info('Auto-Updating nzbToMedia, Please wait ...')
|
||||
if version_checker.update():
|
||||
# restart nzbToMedia
|
||||
try:
|
||||
del MYAPP
|
||||
except Exception:
|
||||
pass
|
||||
restart()
|
||||
else:
|
||||
logger.error('Update wasn\'t successful, not restarting. Check your log for more information.')
|
||||
|
||||
# Set Current Version
|
||||
logger.info('nzbToMedia Version:{version} Branch:{branch} ({system} {release})'.format
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue