Skip to content

Commit

Permalink
fix(route): daily.ts 骨朵日榜修复 (#17652)
Browse files Browse the repository at this point in the history
* Update daily.ts

fix guduo data

* Update daily.ts

* Update lib/routes/guduodata/daily.ts

原地址已经被官方废弃,新地址是可以正常被访问的
  • Loading branch information
zy84338719 authored Nov 26, 2024
1 parent fdfd7e0 commit 8a9a3b3
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions lib/routes/guduodata/daily.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import dayjs from 'dayjs';
import { art } from '@/utils/render';
import path from 'node:path';

const host = 'http://data.guduodata.com';
const host = 'http://d.guduodata.com';

const types = {
collect: {
Expand Down Expand Up @@ -46,13 +46,13 @@ export const route: Route = {
},
radar: [
{
source: ['data.guduodata.com/'],
source: ['guduodata.com/'],
},
],
name: '日榜',
maintainers: ['Gem1ni'],
handler,
url: 'data.guduodata.com/',
url: 'guduodata.com/',
};

async function handler() {
Expand All @@ -65,7 +65,7 @@ async function handler() {
type: key,
name: `[${yestoday}] ${types[key].name} - ${types[key].categories[category]}`,
category: category.toUpperCase(),
url: `${host}/show/datalist?type=DAILY&category=${category.toUpperCase()}&date=${yestoday}`,
url: `${host}/m/v3/billboard/list?type=DAILY&category=${category.toUpperCase()}&date=${yestoday}`,
}))
);
return {
Expand All @@ -76,7 +76,7 @@ async function handler() {
items.map((item) =>
cache.tryGet(item.url, async () => {
const response = await got.get(`${item.url}&t=${now}`, {
headers: { Referer: `http://data.guduodata.com/` },
headers: { Referer: `http://guduodata.com/` },
});
const data = response.data.data;
return {
Expand Down

0 comments on commit 8a9a3b3

Please sign in to comment.