Node.js based forum software built for the modern web
fix: redir on bad world filter
Julian Lam0cf6af9b6c0f
diff --git a/src/controllers/activitypub/topics.js b/src/controllers/activitypub/topics.jsindex 50a9984d35..6c41944dc7 100644--- a/src/controllers/activitypub/topics.js+++ b/src/controllers/activitypub/topics.js@@ -9,7 +9,7 @@ const helpers = require('../helpers');const controller = module.exports;-controller.list = async function (req, res) {+controller.list = async function (req, res, next) {const { topicsPerPage } = await user.getSettings(req.uid);const page = parseInt(req.query.page, 10) || 1;const start = Math.max(0, (page - 1) * topicsPerPage);@@ -18,6 +18,8 @@ controller.list = async function (req, res) {const sets = ['cid:-1:tids', `uid:${req.uid}:inbox`];if (req.params.filter === 'all' || !req.uid) {sets.pop();+ } else if (req.params.filter) {+ return helpers.redirect(res, '/world', false);}const tids = await db.getSortedSetRevIntersect({