解决澎湃新闻条目过多超时的问题 (#684)
This commit is contained in:
parent
97886d5f51
commit
11270cbbdc
|
|
@ -16,7 +16,9 @@ module.exports = async (ctx) => {
|
|||
|
||||
const data = res.data;
|
||||
const $ = cheerio.load(data);
|
||||
const list = $('p.news_tit01, div.news_tit02').get();
|
||||
const list = $('p.news_tit01, div.news_tit02')
|
||||
.slice(0, 10)
|
||||
.get();
|
||||
|
||||
const out = await Promise.all(
|
||||
list.map(async (item) => {
|
||||
|
|
|
|||
Loading…
Reference in New Issue