Prevent server crash if author is not set

This commit is contained in:
Gared 2014-12-27 14:26:05 +01:00
parent 444bbf4cbc
commit 40c7ee9df9
1 changed files with 1 additions and 1 deletions

View File

@ -1020,7 +1020,7 @@ function handleClientReady(client, message)
{
authorManager.getAuthor(authorId, function(err, author)
{
if(ERR(err, callback)) return;
if(ERR(err, callback) || !author) return;
historicalAuthorData[authorId] = {name: author.name, colorId: author.colorId}; // Filter author attribs (e.g. don't send author's pads to all clients)
callback();
});