style: auto format
This commit is contained in:
+11
-11
@@ -10,8 +10,8 @@ const types = {
|
||||
name: '汇总榜',
|
||||
categories: {
|
||||
drama: '连续剧',
|
||||
variety: '综艺'
|
||||
}
|
||||
variety: '综艺',
|
||||
},
|
||||
},
|
||||
bill: {
|
||||
name: '排行榜',
|
||||
@@ -21,9 +21,9 @@ const types = {
|
||||
network_variety: '网络综艺',
|
||||
tv_drama: '电视剧',
|
||||
tv_variety: '电视综艺',
|
||||
anime: '国漫'
|
||||
}
|
||||
}
|
||||
anime: '国漫',
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
@@ -36,7 +36,7 @@ module.exports = async (ctx) => {
|
||||
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}/show/datalist?type=DAILY&category=${category.toUpperCase()}&date=${yestoday}`,
|
||||
}))
|
||||
);
|
||||
ctx.state.data = {
|
||||
@@ -44,10 +44,10 @@ module.exports = async (ctx) => {
|
||||
link: host,
|
||||
description: yestoday,
|
||||
item: await Promise.all(
|
||||
items.map((item) => ctx.cache.tryGet(item.url,
|
||||
async () => {
|
||||
items.map((item) =>
|
||||
ctx.cache.tryGet(item.url, async () => {
|
||||
const response = await got.get(`${item.url}&t=${now}`, {
|
||||
headers: { Referer: `http://data.guduodata.com/`, },
|
||||
headers: { Referer: `http://data.guduodata.com/` },
|
||||
});
|
||||
const data = response.data.data;
|
||||
return {
|
||||
@@ -58,6 +58,6 @@ module.exports = async (ctx) => {
|
||||
};
|
||||
})
|
||||
)
|
||||
)
|
||||
),
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user