mirror of
https://github.com/DIYgod/RSSHub.git
synced 2025-12-15 01:30:33 +08:00
refactor: rename axios to got
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
const axios = require('@/utils/axios');
|
||||
const got = require('@/utils/got');
|
||||
const { ProcessFeed } = require('./utils');
|
||||
|
||||
module.exports = async (ctx) => {
|
||||
const id = ctx.params.id;
|
||||
const link = `https://vocus.cc/user/@${id}`;
|
||||
|
||||
const { _id, fullname, intro } = (await axios({
|
||||
const { _id, fullname, intro } = (await got({
|
||||
method: 'get',
|
||||
url: `https://api.sosreader.com/api/users/${id}`,
|
||||
headers: {
|
||||
@@ -13,7 +13,7 @@ module.exports = async (ctx) => {
|
||||
},
|
||||
})).data;
|
||||
|
||||
const { articles } = (await axios({
|
||||
const { articles } = (await got({
|
||||
method: 'get',
|
||||
url: `https://api.sosreader.com/api/articles?userId=${_id}&num=10&status=2&sort=lastPublishAt`,
|
||||
headers: {
|
||||
|
||||
Reference in New Issue
Block a user