mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-08 15:05:46 +01:00
fix categories.loadMore so it checks read permission
This commit is contained in:
@@ -44,6 +44,10 @@ SocketCategories.loadMore = function(socket, data, callback) {
|
||||
return callback(err);
|
||||
}
|
||||
|
||||
if (!results.privileges.read) {
|
||||
return callback(new Error('[[error:no-privileges]]'));
|
||||
}
|
||||
|
||||
var start = parseInt(data.after, 10),
|
||||
end = start + results.settings.topicsPerPage - 1;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user