Skip to content

Commit fa9f552

Browse files
committed
fix: kaopu source
1 parent 7e88e14 commit fa9f552

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

server/sources/kaopu.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,17 @@ type Res = {
22
description: string
33
link: string
44
// Date
5-
pubDate: string
5+
pub_date: string
66
publisher: string
77
title: string
88
}[]
99
export default defineSource(async () => {
10-
const res = await Promise.all(["https://kaopustorage.blob.core.windows.net/jsondata/news_list_beta_hans_0.json", "https://kaopustorage.blob.core.windows.net/jsondata/news_list_beta_hans_1.json"].map(url => myFetch(url) as Promise<Res>))
11-
return res.flat().filter(k => ["财新", "公视"].every(h => k.publisher !== h)).map((k) => {
10+
const res: Res = await $fetch("https://kaopustorage.blob.core.windows.net/news-prod/news_list_hans_0.json")
11+
return res.filter(k => ["财新", "公视"].every(h => k.publisher !== h)).map((k) => {
1212
return {
1313
id: k.link,
1414
title: k.title,
15-
pubDate: k.pubDate,
15+
pubDate: k.pub_date,
1616
extra: {
1717
hover: k.description,
1818
info: k.publisher,

0 commit comments

Comments
 (0)