This commit is contained in:
thsrite 2023-09-18 10:29:27 +08:00
parent 7e0cad8491
commit cadd885dbf

View File

@ -272,8 +272,8 @@ class Emby(metaclass=Singleton):
return None return None
return "" return ""
def get_movies(self, def get_movies(self,
title: str, title: str,
year: str = None, year: str = None,
tmdb_id: int = None) -> Optional[List[dict]]: tmdb_id: int = None) -> Optional[List[dict]]:
""" """
@ -338,10 +338,12 @@ class Emby(metaclass=Singleton):
if not item_id: if not item_id:
return {} return {}
# 验证tmdbid是否相同 # 验证tmdbid是否相同
item_tmdbid = (self.get_iteminfo(item_id).get("ProviderIds") or {}).get("Tmdb") item_info = self.get_iteminfo(item_id)
if tmdb_id and item_tmdbid: if item_info:
if str(tmdb_id) != str(item_tmdbid): item_tmdbid = (item_info.get("ProviderIds") or {}).get("Tmdb")
return {} if tmdb_id and item_tmdbid:
if str(tmdb_id) != str(item_tmdbid):
return {}
# /Shows/Id/Episodes 查集的信息 # /Shows/Id/Episodes 查集的信息
if not season: if not season:
season = "" season = ""