Skip to content

Commit

Permalink
feat: 使用抓取的数据中的ori_title时同时使用title
Browse files Browse the repository at this point in the history
  • Loading branch information
cnzgray committed Nov 8, 2024
1 parent aa93722 commit 37b5f64
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions javsp/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,14 @@ def info_summary(movie: Movie, all_info: Dict[str, MovieInfo]):
if (current is None) and (incoming is not None):
setattr(final_info, attr, incoming)
absorbed.append(attr)
elif attr == 'ori_title':
# 如果要使用抓取的数据中的ori_title,则也要同时使用title
if (not current) and (incoming):
setattr(final_info, attr, incoming)
incoming_title = getattr(data, 'title')
if incoming_title:
setattr(final_info, 'title', incoming_title)
absorbed.append(attr)
else:
if (not current) and (incoming):
setattr(final_info, attr, incoming)
Expand Down

0 comments on commit 37b5f64

Please sign in to comment.