fix(route/latepost): incorrect pubDate (#18608)

This commit is contained in:
Ethan Shen 2025-03-15 11:24:16 +08:00 committed by GitHub
parent c6216990b2
commit e8346f77ff
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -101,7 +101,7 @@ async function handler(ctx) {
const pubDate = content('div.article-header-date').text();
if (pubDate) {
item.pubDate = /\d+月\d+日/.test(pubDate) ? parseDate(pubDate, ['MM月DD日 HH:mm', 'YYYY年MM月DD日 HH:mm']) : parseRelativeDate(pubDate);
item.pubDate = /\d+月\d+日/.test(pubDate) ? parseDate(pubDate, ['YYYY年MM月DD日 HH:mm', 'MM月DD日 HH:mm']) : parseRelativeDate(pubDate);
}
item.pubDate = timezone(item.pubDate, +8);