fix MediaType

This commit is contained in:
jxxghp
2023-07-07 15:41:53 +08:00
parent 89f2b60e7c
commit 39165a92f0
3 changed files with 4 additions and 4 deletions

View File

@ -92,7 +92,7 @@ async def tmdb_info(tmdbid: int, type_name: str,
"""
根据TMDBID查询themoviedb媒体信息type_name: 电影/电视剧
"""
mtype = MediaType.MOVIE if type_name == MediaType.MOVIE.value else MediaType.TV
mtype = MediaType(type_name)
tmdbinfo = TmdbChain().tmdb_info(tmdbid=tmdbid, mtype=mtype)
if not tmdbinfo:
return schemas.MediaInfo()