version check every 2 hours
This commit is contained in:
@@ -290,10 +290,10 @@ class Service(xbmc.Player):
|
||||
|
||||
|
||||
monitor = Service()
|
||||
last_progress_update = time.time()
|
||||
download_utils.checkVersion()
|
||||
home_window = HomeWindow()
|
||||
last_progress_update = time.time()
|
||||
last_content_check = time.time()
|
||||
last_version_check = 0
|
||||
|
||||
# monitor.abortRequested() is causes issues, it currently triggers for all addon cancelations which causes
|
||||
# the service to exit when a user cancels an addon load action. This is a bug in Kodi.
|
||||
@@ -320,6 +320,11 @@ while not xbmc.abortRequested:
|
||||
last_content_check = time.time()
|
||||
checkForNewContent()
|
||||
|
||||
# check version
|
||||
if (time.time() - last_version_check) > (60 * 60 * 2): # every 2 hours
|
||||
last_version_check = time.time()
|
||||
download_utils.checkVersion()
|
||||
|
||||
except Exception as error:
|
||||
log.error("Exception in Playback Monitor : " + str(error))
|
||||
log.error(traceback.format_exc())
|
||||
|
||||
Reference in New Issue
Block a user