mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-27 17:16:14 +01:00
misc fixes
handle spider uids properly
This commit is contained in:
@@ -19,7 +19,7 @@ SocketGroups.before = function (socket, method, data, next) {
|
||||
};
|
||||
|
||||
SocketGroups.join = function (socket, data, callback) {
|
||||
if (!parseInt(socket.uid, 10)) {
|
||||
if (socket.uid <= 0) {
|
||||
return callback(new Error('[[error:invalid-uid]]'));
|
||||
}
|
||||
|
||||
@@ -60,7 +60,7 @@ SocketGroups.join = function (socket, data, callback) {
|
||||
};
|
||||
|
||||
SocketGroups.leave = function (socket, data, callback) {
|
||||
if (!parseInt(socket.uid, 10)) {
|
||||
if (socket.uid <= 0) {
|
||||
return callback(new Error('[[error:invalid-uid]]'));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user