Skip to content

Commit

Permalink
Fixed anidb refiner special episodes without offset (#2736)
Browse files Browse the repository at this point in the history
  • Loading branch information
anderson-oki authored Oct 26, 2024
1 parent 239ab78 commit 23c19db
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions bazarr/subtitles/refiners/anidb.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,11 +91,11 @@ def get_show_information(self, tvdb_series_id, tvdb_series_season, episode):
return None, None, None

is_special_entry = True

for special_entry in special_entries:
mapping_list = special_entry.findall(f".//mapping[@tvdbseason='{tvdb_series_season}']")
if len(mapping_list) > 0:
anidb_id = int(special_entry.attrib.get('anidbid'))
offset = int(mapping_list[0].attrib.get('offset', 0))
anidb_id = int(special_entry.attrib.get('anidbid'))
offset = int(mapping_list[0].attrib.get('offset', 0)) if len(mapping_list) > 0 else 0

if not is_special_entry:
# Sort the anime by offset in ascending order
Expand Down

0 comments on commit 23c19db

Please sign in to comment.