mirror of
https://github.com/DIYgod/RSSHub.git
synced 2026-08-30 16:55:08 +08:00
fix(route/nea): remove vibe types
This commit is contained in:
@@ -50,7 +50,7 @@ async function handler(ctx) {
|
||||
|
||||
const jsonData: NeaGhsResponse = await ofetch(jsonUrl);
|
||||
|
||||
const list: InternalDataItem[] = jsonData.datasource.slice(0, limit).map((item) => {
|
||||
const list: DataItem[] = jsonData.datasource.slice(0, limit).map((item) => {
|
||||
const itemLink = new URL(item.publishUrl, rootUrl).href;
|
||||
|
||||
const $title = load(item.showTitle);
|
||||
@@ -69,7 +69,7 @@ async function handler(ctx) {
|
||||
});
|
||||
|
||||
const items = await Promise.all(
|
||||
list.map((item: InternalDataItem) =>
|
||||
list.map((item: DataItem) =>
|
||||
cache.tryGet(item.link, async () => {
|
||||
try {
|
||||
const detailResponse = await ofetch(item.link);
|
||||
@@ -115,12 +115,3 @@ interface NeaGhsResponse {
|
||||
categoryDesc?: string;
|
||||
datasource: NeaGhsItem[];
|
||||
}
|
||||
|
||||
interface InternalDataItem {
|
||||
title: string;
|
||||
link: string;
|
||||
pubDate: Date;
|
||||
description: string;
|
||||
author?: string;
|
||||
category: string[];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user