diff --git a/lib/routes/infzm/news.js b/lib/routes/infzm/news.js index 4ed89f8114a6fe..5759a289b637b1 100644 --- a/lib/routes/infzm/news.js +++ b/lib/routes/infzm/news.js @@ -1,4 +1,5 @@ const got = require('@/utils/got'); +const timezone = require('@/utils/timezone'); const cheerio = require('cheerio'); const baseUrl = 'http://www.infzm.com/contents'; @@ -16,7 +17,8 @@ module.exports = async (ctx) => { const data = response.data.data; const resultItem = await Promise.all( data.contents.map(async ({ id, subject, author, publish_time }) => { - const date = new Date(publish_time); + // the timezone is GMT+8 + const date = timezone(publish_time, +8); const link = `http://www.infzm.com/contents/${id}`; let description = '';