mirror of
https://github.com/DIYgod/RSSHub.git
synced 2026-10-24 23:42:40 +08:00
增加了对新榜未收录数据的订阅,并强制登陆信息为String (#5438)
This commit is contained in:
@@ -69,8 +69,8 @@ async function getCookie(ctx) {
|
||||
// Check if this key should be replace? every 30 times should be fine.
|
||||
await shouldUpdateCookie(ctx);
|
||||
let token = await ctx.cache.get(newrank_cookie_token);
|
||||
const username = config.newrank.username;
|
||||
const password = md5(md5(config.newrank.password) + 'daddy');
|
||||
const username = String(config.newrank.username);
|
||||
const password = md5(md5(String(config.newrank.password)) + 'daddy');
|
||||
const nonce = random_nonce(9);
|
||||
const xyz = decrypt_login_xyz(username, password, nonce);
|
||||
if (!token) {
|
||||
|
||||
@@ -18,9 +18,11 @@ module.exports = async (ctx) => {
|
||||
},
|
||||
});
|
||||
const name = response.data.value.user.name;
|
||||
const realTimeArticles = utils.flatten(response.data.value.realTimeArticles);
|
||||
const articles = utils.flatten(response.data.value.articles);
|
||||
const newArticles = realTimeArticles.concat(articles);
|
||||
const items = await Promise.all(
|
||||
articles.map(async (item) => ({
|
||||
newArticles.map(async (item) => ({
|
||||
title: item.title,
|
||||
description: '',
|
||||
link: item.url,
|
||||
|
||||
Reference in New Issue
Block a user