Fixed TypeError: list indices must be integers, not list that occured during searches

This commit is contained in:
echel0n 2014-09-06 16:55:39 -07:00
parent a0ef748f3b
commit 4af28657af

View file

@ -261,10 +261,10 @@ class GenericProvider:
# search cache for episode result
cacheResult = self.cache.searchCache(epObj, manualSearch)
if cacheResult:
if epObj not in results:
results = [cacheResult]
if epObj.episode not in results:
results[epObj.episode] = [result]
else:
results.append(cacheResult)
results[epObj.episode].append(result)
# found result, search next episode
continue