fix(route): odaily remove newflash from post (#9233)
This commit is contained in:
parent
116e27a2ce
commit
3d07b9f87a
|
|
@ -25,14 +25,16 @@ module.exports = async (ctx) => {
|
|||
url: currentUrl,
|
||||
});
|
||||
|
||||
let items = response.data.data.items.map((item) => ({
|
||||
title: item.title,
|
||||
author: item.user.name,
|
||||
type: item.entity_type,
|
||||
description: `<p>${item.summary}</p>`,
|
||||
link: `${rootUrl}/${item.entity_type}/${item.entity_id}`,
|
||||
pubDate: timezone(parseDate(item.published_at), +8),
|
||||
}));
|
||||
let items = response.data.data.items
|
||||
.map((item) => ({
|
||||
title: item.title,
|
||||
author: item.user.name,
|
||||
type: item.entity_type,
|
||||
description: `<p>${item.summary}</p>`,
|
||||
link: `${rootUrl}/${item.entity_type}/${item.entity_id}`,
|
||||
pubDate: timezone(parseDate(item.published_at), +8),
|
||||
}))
|
||||
.filter((item) => item.type !== 'newsflash');
|
||||
|
||||
items = await Promise.all(
|
||||
items.map(
|
||||
|
|
|
|||
Loading…
Reference in New Issue