Merge pull request #386 from InfinityPacer/main

This commit is contained in:
jxxghp
2024-06-17 21:08:17 +08:00
committed by GitHub
2 changed files with 8 additions and 7 deletions

View File

@@ -394,11 +394,12 @@
"name": "演职人员刮削",
"description": "刮削演职人员图片以及中文名称。",
"labels": "媒体库,刮削",
"version": "1.3",
"version": "1.4",
"icon": "actor.png",
"author": "jxxghp",
"level": 1,
"history": {
"v1.4": "人物图片调整为优先从TMDB获取避免douban图片CDN加载过慢的问题",
"v1.3": "修复v1.8.5版本后刮削报错问题"
}
},

View File

@@ -40,7 +40,7 @@ class PersonMeta(_PluginBase):
# 插件图标
plugin_icon = "actor.png"
# 插件版本
plugin_version = "1.3"
plugin_version = "1.4"
# 插件作者
plugin_author = "jxxghp"
# 作者主页
@@ -514,6 +514,11 @@ class PersonMeta(_PluginBase):
person_detail = self.tmdbchain.person_detail(int(person_tmdbid))
if person_detail:
cn_name = self.__get_chinese_name(person_detail)
# 图片优先从TMDB获取
profile_path = person_detail.profile_path
if profile_path:
logger.debug(f"{people.get('Name')} 从TMDB获取到图片{profile_path}")
profile_path = f"https://{settings.TMDB_IMAGE_DOMAIN}/t/p/original{profile_path}"
if cn_name:
# 更新中文名
logger.debug(f"{people.get('Name')} 从TMDB获取到中文名{cn_name}")
@@ -526,11 +531,6 @@ class PersonMeta(_PluginBase):
logger.debug(f"{people.get('Name')} 从TMDB获取到中文描述")
personinfo["Overview"] = biography
updated_overview = True
# 图片
profile_path = person_detail.profile_path
if profile_path:
logger.debug(f"{people.get('Name')} 从TMDB获取到图片{profile_path}")
profile_path = f"https://{settings.TMDB_IMAGE_DOMAIN}/t/p/original{profile_path}"
# 从豆瓣信息中更新人物信息
"""