Skip to content

Commit

Permalink
Fixed podnapisi search results parsing error
Browse files Browse the repository at this point in the history
  • Loading branch information
morpheus65535 committed Dec 31, 2023
1 parent a7b84df commit b11f810
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libs/subliminal_patch/providers/podnapisi.py
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ def query(self, language, keyword, video, season=None, episode=None, year=None,
break

# exit if no results
if not int(xml.find('pagination/results').text):
if not xml.find('pagination/results') or not int(xml.find('pagination/results').text):
logger.debug('No subtitles found')
break

Expand Down

1 comment on commit b11f810

@morpheus65535
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@morpheus65535 I'm not sure if this is working properly, for example for this query

https://www.podnapisi.net/subtitles/search/old?sXML=1&sL=en&sK=halo&sTS=2&sTE=1&sY=2022

It will return "No subtitles found", even though there are two.

Are you able to submit a PR with a proper fix?

Please sign in to comment.