mirror of
https://github.com/DIYgod/RSSHub.git
synced 2025-12-14 01:00:38 +08:00
fix: github trending url URLencode (#3115)
This commit is contained in:
@@ -4,7 +4,7 @@ const cheerio = require('cheerio');
|
|||||||
module.exports = async (ctx) => {
|
module.exports = async (ctx) => {
|
||||||
const since = ctx.params.since;
|
const since = ctx.params.since;
|
||||||
const language = ctx.params.language || '';
|
const language = ctx.params.language || '';
|
||||||
const url = `https://github.com/trending/${language}?since=${since}`;
|
const url = `https://github.com/trending/${encodeURIComponent(language)}?since=${since}`;
|
||||||
|
|
||||||
const response = await got({
|
const response = await got({
|
||||||
method: 'get',
|
method: 'get',
|
||||||
|
|||||||
Reference in New Issue
Block a user