Skip to content

Commit 8ded6bd

Browse files
authored
修复豆瓣榜单问题 (#10887)
1 parent de48ec5 commit 8ded6bd

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

lib/v2/douban/other/weekly_best.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,13 @@ module.exports = async (ctx) => {
2828
link: `https://m.douban.com/subject_collection/${type}`,
2929
description: infoResponse.data.description,
3030

31-
item: data.map(({ title, info, cover, url, rating, year, release_date, null_rating_reason, description }) => {
31+
item: data.map(({ title, info, cover, cover_url, url, rating, year, release_date, null_rating_reason, description }) => {
3232
const release = `${year}.${release_date}`;
3333
const rate = rating ? `${rating.value.toFixed(1)}分` : null_rating_reason;
34-
35-
description = `标题:${title} <br> 影片信息:${info} <br> 上映日期:${release} <br> 评分:${rate} <br> <img src="${cover.url}"> <p>${description}</p>`;
34+
if (cover && cover.url) {
35+
cover_url = cover.url;
36+
}
37+
description = `标题:${title} <br> 影片信息:${info} <br> 上映日期:${release} <br> 评分:${rate} <br> <img src="${cover_url}"> <p>${description}</p>`;
3638

3739
return {
3840
title,

0 commit comments

Comments
 (0)