Fixed podnapisi TypeError since we've merged #2790.

pull/2734/merge v1.5.2-beta.7
morpheus65535 1 month ago
parent 214b8153ae
commit 6fc6ca5ec2

@ -204,12 +204,12 @@ class PodnapisiProvider(_PodnapisiProvider, ProviderSubtitleArchiveMixin):
# query the server
content = None
try:
content = self.session.get(self.server_url + 'search/old', params=params, timeout=30).content
xml = etree.fromstring(content)
content = self.session.get(self.server_url + 'search/old', params=params, timeout=30)
xml = etree.fromstring(content.content)
except etree.ParseError:
if '429 Too Many Requests' in content:
if '429 Too Many Requests' in content.text:
raise TooManyRequests
logger.error("Wrong data returned: %r", content)
logger.error("Wrong data returned: %r", content.text)
break
# exit if no results

Loading…
Cancel
Save