mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-31 19:15:58 +01:00
closes #5443
This commit is contained in:
@@ -69,7 +69,7 @@ categoryController.get = function (req, res, callback) {
|
||||
}
|
||||
|
||||
if (!settings.usePagination) {
|
||||
topicIndex = Math.max(topicIndex - (settings.topicsPerPage - 1), 0);
|
||||
topicIndex = Math.max(0, topicIndex - (Math.ceil(settings.topicsPerPage / 2) - 1));
|
||||
} else if (!req.query.page) {
|
||||
var index = Math.max(parseInt((topicIndex || 0), 10), 0);
|
||||
currentPage = Math.ceil((index + 1) / settings.topicsPerPage);
|
||||
|
||||
Reference in New Issue
Block a user