From 442631105b8d6af6242877ff995dd19c1a1517e3 Mon Sep 17 00:00:00 2001 From: echel0n Date: Sun, 14 Sep 2014 18:24:08 -0700 Subject: [PATCH] Fix for TypeError: list indices must be integers, not str in Indexer API code --- lib/tvdb_api/tvdb_api.py | 2 +- lib/tvrage_api/tvrage_api.py | 2 +- sickbeard/webserve.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/tvdb_api/tvdb_api.py b/lib/tvdb_api/tvdb_api.py index 68071a29..ed4c0d34 100644 --- a/lib/tvdb_api/tvdb_api.py +++ b/lib/tvdb_api/tvdb_api.py @@ -842,7 +842,7 @@ class Tvdb: ) # check and make sure we have data to process and that it contains a series name - if seriesInfoEt is None or 'seriesname' not in seriesInfoEt['series']: + if not len(seriesInfoEt) or (isinstance(seriesInfoEt, dict) and 'seriesname' not in seriesInfoEt['series']): return False for k, v in seriesInfoEt['series'].items(): diff --git a/lib/tvrage_api/tvrage_api.py b/lib/tvrage_api/tvrage_api.py index 09943837..e5fcbf10 100644 --- a/lib/tvrage_api/tvrage_api.py +++ b/lib/tvrage_api/tvrage_api.py @@ -592,7 +592,7 @@ class TVRage: ) # check and make sure we have data to process and that it contains a series name - if seriesInfoEt is None or 'seriesname' not in seriesInfoEt: + if not len(seriesInfoEt) or (isinstance(seriesInfoEt, dict) and 'seriesname' not in seriesInfoEt['series']): return False for k, v in seriesInfoEt.items(): diff --git a/sickbeard/webserve.py b/sickbeard/webserve.py index 44dfcf74..90f31d86 100644 --- a/sickbeard/webserve.py +++ b/sickbeard/webserve.py @@ -3628,7 +3628,7 @@ class Home(MainHandler): show_message = 'This show is in the process of being downloaded - the info below is incomplete.' elif sickbeard.showQueueScheduler.action.isBeingUpdated(showObj): # @UndefinedVariable - show_message = 'The information below is in the process of being updated.' + show_message = 'The information on this page is in the process of being updated.' elif sickbeard.showQueueScheduler.action.isBeingRefreshed(showObj): # @UndefinedVariable show_message = 'The episodes below are currently being refreshed from disk'