mirror of
https://github.com/morpheus65535/bazarr
synced 2024-12-22 15:54:26 +00:00
Fixed animetosho empty language fallback (#2571)
This commit is contained in:
parent
96af60918e
commit
12e7bbfb01
1 changed files with 2 additions and 1 deletions
|
@ -141,7 +141,8 @@ class AnimeToshoProvider(Provider, ProviderSubtitleArchiveMixin):
|
||||||
for subtitle_file in subtitle_files:
|
for subtitle_file in subtitle_files:
|
||||||
hex_id = format(subtitle_file['id'], '08x')
|
hex_id = format(subtitle_file['id'], '08x')
|
||||||
|
|
||||||
lang = Language.fromalpha3b(subtitle_file['info']['lang'])
|
# Animetosho assumes missing languages as english as fallback when not specified.
|
||||||
|
lang = Language.fromalpha3b(subtitle_file['info'].get('lang', 'eng'))
|
||||||
|
|
||||||
# For Portuguese and Portuguese Brazilian they both share the same code, the name is the only
|
# For Portuguese and Portuguese Brazilian they both share the same code, the name is the only
|
||||||
# identifier AnimeTosho provides. Also, some subtitles does not have name, in this case it could
|
# identifier AnimeTosho provides. Also, some subtitles does not have name, in this case it could
|
||||||
|
|
Loading…
Reference in a new issue