Skip to content

Commit

Permalink
Update realtime.js
Browse files Browse the repository at this point in the history
  • Loading branch information
dzx-dzx authored Sep 3, 2023
1 parent d6c73e5 commit 4647778
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/v2/stheadline/std/realtime.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ module.exports = async (ctx) => {
title: e.title,
link: e.articleLink,
guid: e.articleLink.substring(0, e.articleLink.lastIndexOf('/')),
pubDate: timezone(parseDate(e.publish_datetime), +8),
}));

// const items = $(`${category === '即時' ? '.moreNews > .col-md-4' : ''} .media-body > .my-2 > a`)
Expand All @@ -65,6 +64,7 @@ module.exports = async (ctx) => {
const $ = cheerio.load(response);

item.description = $('.paragraphs').html();
item.pubDate = timezone(parseDate($('.content .date').text()), +8);

return item;
})
Expand Down

1 comment on commit 4647778

@dzx-dzx
Copy link
Contributor Author

@dzx-dzx dzx-dzx commented on 4647778 Sep 3, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The property publish_datetime can both be absolute and relative.

Please sign in to comment.