fix 兼容emby webhook删除season没有tmdbid

This commit is contained in:
thsrite
2023-11-01 11:51:07 +08:00
parent 45fb8e86bf
commit 382035768e
2 changed files with 22 additions and 11 deletions

View File

@ -158,6 +158,13 @@ class TransferHistory(Base):
# 电视剧所有季集
result = db.query(TransferHistory).filter(TransferHistory.title == title,
TransferHistory.year == year).all()
# 类型 + 转移路径emby webhook season无tmdbid场景
elif mtype and season and dest:
# 电视剧某季
result = db.query(TransferHistory).filter(TransferHistory.type == mtype,
TransferHistory.seasons == season,
TransferHistory.dest.like(f"{dest}%")).all()
if result:
return list(result)
return []