From 791a50a01b2de05243fd6d5a732b1ca1c1f4427c Mon Sep 17 00:00:00 2001 From: Baris Soner Usakli Date: Fri, 14 Feb 2014 20:46:00 -0500 Subject: [PATCH] closes #1028 --- src/categories.js | 2 +- src/socket.io/admin.js | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/categories.js b/src/categories.js index b13ece6535..82a190c345 100644 --- a/src/categories.js +++ b/src/categories.js @@ -176,7 +176,7 @@ var db = require('./database'), }; Categories.getModerators = function(cid, callback) { - Groups.getByGroupName('cid:' + cid + ':privileges:mod', {}, function(err, groupObj) { + Groups.getByGroupName('cid:' + cid + ':privileges:mods', {}, function(err, groupObj) { if (!err) { if (groupObj.members && groupObj.members.length) { user.getMultipleUserFields(groupObj.members, ['uid', 'username', 'userslug', 'picture'], function(err, moderators) { diff --git a/src/socket.io/admin.js b/src/socket.io/admin.js index 535be06be5..da1de17596 100644 --- a/src/socket.io/admin.js +++ b/src/socket.io/admin.js @@ -215,6 +215,7 @@ SocketAdmin.categories.getPrivilegeSettings = function(socket, cid, callback) { }; SocketAdmin.categories.setGroupPrivilege = function(socket, data, callback) { + if(!data) { return callback(new Error('invalid data')); }