mirror of
https://github.com/SickGear/SickGear.git
synced 2025-01-05 17:43:37 +00:00
Only walk lists if they are populated.
This commit is contained in:
parent
363db60a3d
commit
e475d2a22d
1 changed files with 5 additions and 2 deletions
|
@ -250,13 +250,16 @@ class GenericProvider:
|
|||
searchStrings += self._get_episode_search_strings(epObj)
|
||||
|
||||
# remove duplicate search strings
|
||||
searchStrings = [i for n, i in enumerate(searchStrings) if i not in searchStrings[n + 1:]]
|
||||
if len(searchString):
|
||||
searchStrings = [i for n, i in enumerate(searchStrings) if i not in searchStrings[n + 1:]]
|
||||
|
||||
for curString in sorted(searchStrings):
|
||||
itemList += self._doSearch(curString)
|
||||
|
||||
# remove duplicate items
|
||||
itemList = list(set(itemList))
|
||||
if len(itemLisT):
|
||||
itemList = list(set(itemList))
|
||||
|
||||
for item in itemList:
|
||||
|
||||
(title, url) = self._get_title_and_url(item)
|
||||
|
|
Loading…
Reference in a new issue