mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-08-13 01:48:42 +02:00
fix: gate /world behind ensureLoggedIn middleware
This commit is contained in:
@@ -16,10 +16,6 @@ const helpers = require('../helpers');
|
||||
const controller = module.exports;
|
||||
|
||||
controller.list = async function (req, res) {
|
||||
if (!req.uid) {
|
||||
return helpers.redirect(res, '/recent?cid=-1', false);
|
||||
}
|
||||
|
||||
const { topicsPerPage } = await user.getSettings(req.uid);
|
||||
const page = parseInt(req.query.page, 10) || 1;
|
||||
const start = Math.max(0, (page - 1) * topicsPerPage);
|
||||
|
||||
Reference in New Issue
Block a user