mirror of
https://github.com/DIYgod/RSSHub.git
synced 2025-12-09 23:00:48 +08:00
refactor: rename axios to got
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
const axios = require('@/utils/axios');
|
||||
const got = require('@/utils/got');
|
||||
const parser = require('@/utils/rss-parser');
|
||||
const cheerio = require('cheerio');
|
||||
|
||||
@@ -56,7 +56,7 @@ const getData = async ({ site = 'www', channel }) => {
|
||||
|
||||
const items = await Promise.all(
|
||||
feed.items.splice(0, 10).map(async (item) => {
|
||||
const response = await axios.get(`${item.link}?full=y&archive`);
|
||||
const response = await got.get(`${item.link}?full=y&archive`);
|
||||
|
||||
const $ = cheerio.load(response.data);
|
||||
const result = ProcessFeed($, item.link);
|
||||
|
||||
Reference in New Issue
Block a user