diff --git a/servers/torrent.py b/servers/torrent.py index 0e9e56bd..b13091d3 100755 --- a/servers/torrent.py +++ b/servers/torrent.py @@ -94,8 +94,8 @@ def elementum_monitor(): Monitor = json['monitor'] # else create it else: - json = jsontools.load('{"monitor":{},"settings":{}}') - json = jsontools.dump(json) + Monitor = jsontools.load('{"monitor":{},"settings":{}}') + json = jsontools.dump(Monitor) filetools.write(monitor, json, silent=True) if len(Monitor) > 0: diff --git a/service.py b/service.py index f9509be1..5ac60ff5 100644 --- a/service.py +++ b/service.py @@ -385,7 +385,10 @@ if __name__ == "__main__": # mark as stopped all downloads (if we are here, probably kodi just started) from specials.downloads import stop_all - stop_all() + try: + stop_all() + except: + logger.error(traceback.format_exc()) while True: schedule.run_pending()