fix(route): 日期直接从dates对象中获取 (#16761)

This commit is contained in:
moxuy 2024-09-15 20:07:07 +08:00 committed by GitHub
parent be3ba61788
commit 837aa7b0b9
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 2 deletions

View File

@ -82,8 +82,8 @@ async function handler(ctx) {
}),
author: i.newsBylineProps?.authors?.map((a) => a.name).join('/') ?? undefined,
guid: `abc-${i.id}`,
pubDate: parseDate(i.timestamp.dates.firstPublished),
updated: i.timestamp.dates.lastUpdated ? parseDate(i.timestamp.dates.lastUpdated) : undefined,
pubDate: parseDate(i.dates.firstPublished),
updated: i.dates.lastUpdated ? parseDate(i.dates.lastUpdated) : undefined,
};
if (i.mediaIndicator) {