diff --git a/sickbeard/helpers.py b/sickbeard/helpers.py index 13e615f1..4cf00bf7 100644 --- a/sickbeard/helpers.py +++ b/sickbeard/helpers.py @@ -950,10 +950,11 @@ def get_show_by_name(name, useIndexer=False): if cacheResult: in_cache = True foundResult = findCertainShow(sickbeard.showList, cacheResult) - logger.log( - u"Cache lookup found Indexer ID:" + repr( - foundResult.indexerid) + ", using that for " + name, - logger.DEBUG) + if foundResult: + logger.log( + u"Cache lookup found Indexer ID:" + repr( + foundResult.indexerid) + ", using that for " + name, + logger.DEBUG) if not foundResult: logger.log(