Commit e2132a29 authored by echel0n's avatar echel0n
Browse files

Fixed issue#286 - added support for non-english indexer images

parent ef827f75
# Changelog
- * 0929705 - 2018-10-14: Release v9.3.87
- * 8d0178c - 2018-10-14: Fixed issue#286 - added support for non-english indexer images
- * d186f55 - 2018-10-14: Release v9.3.87
- * ca05ceb - 2018-10-14: Fixed issue with freebsd init script not daemonizing the app
- * 10fc6b3 - 2018-10-14: Release v9.3.86
- * b0c7dc9 - 2018-10-13: Release v9.3.85
......
......@@ -644,14 +644,23 @@ class Tvdb:
def images(self, sid, key_type='poster', season=None):
sickrage.app.log.debug('Getting {} images for {}'.format(key_type, sid))
images = []
for language in [self.config['api']['lang'], self.config['language']]:
if len(images):
continue
try:
if not season:
images = self._request('get', self.config['api']['images'][key_type].format(id=sid),
self.config['api']['lang'])['data']
language)['data']
else:
images = self._request('get', self.config['api']['images'][key_type].format(id=sid, season=season),
self.config['api']['lang'])['data']
language)['data']
except tvdb_error:
continue
# unable to retrieve images in languages wanted
if not images:
return []
for i, image in enumerate(images):
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment