mirror of
https://github.com/zoriya/Kyoo.git
synced 2025-05-24 02:02:36 -04:00
Fix themoviedb weird absolute
This commit is contained in:
parent
36f6cd5631
commit
4602f4ee65
@ -662,13 +662,13 @@ class TheMovieDatabase(Provider):
|
||||
start = next(
|
||||
(x["episode_number"] for x in absgrp if x["season_number"] == season), None
|
||||
)
|
||||
if start is not None and start <= episode_nbr:
|
||||
# add back the continuous number (imagine the user has one piece S21e31
|
||||
# but tmdb registered it as S21E831 since S21's first ep is 800
|
||||
return await self.get_absolute_number(show_id, season, episode_nbr + start)
|
||||
raise ProviderError(
|
||||
f"Could not guess absolute number of episode {show_id} s{season} e{episode_nbr}"
|
||||
)
|
||||
if start is None or start <= episode_nbr:
|
||||
raise ProviderError(
|
||||
f"Could not guess absolute number of episode {show_id} s{season} e{episode_nbr}"
|
||||
)
|
||||
# add back the continuous number (imagine the user has one piece S21e31
|
||||
# but tmdb registered it as S21E831 since S21's first ep is 800
|
||||
return await self.get_absolute_number(show_id, season, episode_nbr + start)
|
||||
|
||||
async def identify_collection(self, provider_id: str) -> Collection:
|
||||
languages = self.get_languages()
|
||||
|
Loading…
x
Reference in New Issue
Block a user