mirror of
https://github.com/DIYgod/RSSHub.git
synced 2026-09-24 23:12:34 +08:00
fix(route): Fix Discourse link (#13167)
This commit is contained in:
@@ -7,7 +7,7 @@ module.exports = async (ctx) => {
|
||||
const response = await got(`${link}/notifications.json`, { headers: { 'User-Api-Key': key } }).json();
|
||||
const items = response.notifications.map((e) => ({
|
||||
title: e.fancy_title ?? e.data.badge_name,
|
||||
link: `${link}/${e.data.hasOwnProperty('badge_id') ? `badges/${e.data.badge_id}/${e.data.badge_slug}?username=${e.data.username}` : `${e.topic_id}/${e.post_number}`}`,
|
||||
link: `${link}/${e.data.hasOwnProperty('badge_id') ? `badges/${e.data.badge_id}/${e.data.badge_slug}?username=${e.data.username}` : `t/topic/${e.topic_id}/${e.post_number}`}`,
|
||||
pubDate: new Date(e.created_at),
|
||||
author: e.data.display_username ?? e.data.username,
|
||||
category: `notification_type:${e.notification_type}`,
|
||||
|
||||
Reference in New Issue
Block a user