Fix add custom command where message is empty
This commit is contained in:
parent
2820cf954b
commit
0627e2323f
1 changed files with 2 additions and 2 deletions
|
@ -28,11 +28,11 @@ module.exports = {
|
|||
let customMessage = args.slice(2, args.length).join(" ");
|
||||
switch (args[0].toLowerCase()) {
|
||||
case "add":
|
||||
if(!args[1]) {
|
||||
if(!customMessage) {
|
||||
message.channel.send("Message can't be empty");
|
||||
return;
|
||||
}
|
||||
sendText = addCustomCommand(args[1], customMessage, message.author.id);
|
||||
sendText = addCustomCommand(customName, customMessage, message.author.id);
|
||||
break;
|
||||
case "remove":
|
||||
case "delete":
|
||||
|
|
Loading…
Add table
Reference in a new issue