Check for missing payload on CLIENT_MESSAGE

pull/1431/head
mluto 2013-01-30 15:28:54 +01:00
parent f2742c5b63
commit 7e48e025c7
1 changed files with 1 additions and 0 deletions

View File

@ -210,6 +210,7 @@ exports.handleMessage = function(client, message)
} else if (message.data.type == "SAVE_REVISION") { } else if (message.data.type == "SAVE_REVISION") {
handleSaveRevisionMessage(client, message); handleSaveRevisionMessage(client, message);
} else if (message.data.type == "CLIENT_MESSAGE" && } else if (message.data.type == "CLIENT_MESSAGE" &&
message.data.payload != null &&
message.data.payload.type == "suggestUserName") { message.data.payload.type == "suggestUserName") {
handleSuggestUserName(client, message); handleSuggestUserName(client, message);
} else { } else {