Fix exception if bot mentioned without a command

This commit is contained in:
benji7425 2017-10-02 00:18:05 +01:00
parent ec8b165c96
commit 71e61663e2
1 changed files with 3 additions and 0 deletions

View File

@ -33,6 +33,9 @@ function handleMessage(client, message, commands, guildData) {
/**@param param*/
function handleInternalCommand(message, split, commands, isMemberAdmin) {
if (!split[1])
return;
if (split[1].toLowerCase() === "version")
message.reply(`${ParentPackageJSON.name} v${ParentPackageJSON.version}`);
else if (split[1].toLowerCase() === "help") {