mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-01-01 21:30:30 +01:00
fix: #8929, fix popular, top rss feed urls
This commit is contained in:
@@ -22,7 +22,7 @@ popularController.get = async function (req, res, next) {
|
||||
}
|
||||
|
||||
const feedQs = data.rssFeedUrl.split('?')[1];
|
||||
data.rssFeedUrl = nconf.get('relative_path') + '/popular/' + (validator.escape(String(req.query.term)) || 'alltime') + '.rss';
|
||||
data.rssFeedUrl = nconf.get('relative_path') + '/popular/' + validator.escape(String(req.query.term || 'alltime')) + '.rss';
|
||||
if (req.loggedIn) {
|
||||
data.rssFeedUrl += '?' + feedQs;
|
||||
}
|
||||
|
||||
@@ -20,7 +20,7 @@ topController.get = async function (req, res, next) {
|
||||
}
|
||||
|
||||
const feedQs = data.rssFeedUrl.split('?')[1];
|
||||
data.rssFeedUrl = nconf.get('relative_path') + '/top/' + (validator.escape(String(req.query.term)) || 'alltime') + '.rss';
|
||||
data.rssFeedUrl = nconf.get('relative_path') + '/top/' + validator.escape(String(req.query.term || 'alltime')) + '.rss';
|
||||
if (req.loggedIn) {
|
||||
data.rssFeedUrl += '?' + feedQs;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user