fix del image

This commit is contained in:
thsrite 2023-10-26 14:40:57 +08:00
parent e87fdc896c
commit 78017b8a0e
2 changed files with 8 additions and 12 deletions

View File

@ -106,15 +106,13 @@ class CloudDiskDel(_PluginBase):
image = 'https://emby.media/notificationicon.png' image = 'https://emby.media/notificationicon.png'
media_type = MediaType.MOVIE if media_type in ["Movie", "MOV"] else MediaType.TV media_type = MediaType.MOVIE if media_type in ["Movie", "MOV"] else MediaType.TV
if self._notify: if self._notify:
specific_image = self.chain.obtain_specific_image( poster_image = self.chain.obtain_specific_image(
mediaid=tmdb_id, mediaid=tmdb_id,
mtype=media_type, mtype=media_type,
image_type=MediaImageType.Backdrop, image_type=MediaImageType.Poster,
season=season_num,
episode=episode_num
) )
if specific_image: if poster_image:
image = specific_image image = poster_image
# 类型 # 类型
if media_type == MediaType.MOVIE: if media_type == MediaType.MOVIE:

View File

@ -662,15 +662,13 @@ class MediaSyncDel(_PluginBase):
# 发送消息 # 发送消息
if self._notify: if self._notify:
if not image or media_type == MediaType.TV: if not image or media_type == MediaType.TV:
specific_image = self.chain.obtain_specific_image( poster_image = self.chain.obtain_specific_image(
mediaid=tmdb_id, mediaid=tmdb_id,
mtype=media_type, mtype=media_type,
image_type=MediaImageType.Backdrop, image_type=MediaImageType.Poster,
season=season_num,
episode=episode_num
) )
if specific_image: if poster_image:
image = specific_image image = poster_image
if not image: if not image:
image = 'https://emby.media/notificationicon.png' image = 'https://emby.media/notificationicon.png'