fixed a API Bug

This commit is contained in:
Peter 'Pita' Martischka 2011-08-19 21:35:31 +01:00
parent caecfd3997
commit 82dd4802d7

View file

@ -460,6 +460,13 @@ function handleUserChanges(client, message)
exports.updatePadClients = function(pad, callback) exports.updatePadClients = function(pad, callback)
{ {
//skip this step if noone is on this pad
if(!pad2sessions[pad.id])
{
callback();
return;
}
//go trough all sessions on this pad //go trough all sessions on this pad
async.forEach(pad2sessions[pad.id], function(session, callback) async.forEach(pad2sessions[pad.id], function(session, callback)
{ {