Perms for say because we cant have nice things.

This commit is contained in:
Alex Brow 2020-02-19 20:17:30 -05:00
parent 4c559819a3
commit 23e32b90f0
No known key found for this signature in database
GPG Key ID: F48926893F475C25

View File

@ -75,11 +75,14 @@ client.on("message", async message => {
const sayMessage = args.join(" ");
if(sayMessage.includes('@'))
return message.reply("\nStop pinging yourself \nStop pinging yourself");
else{
else if (!message.member.roles.some(r=>["Admin", "Mods","Member of the Order of the b l u e","Botmeister","Ally of the Order"].includes(r.name)) ) {
// Then we delete the command message (sneaky, right?). The catch just ignores the error with a cute smiley thing.
message.delete().catch(O_o=>{});
// And we get the bot to say the thing:
message.channel.send(sayMessage);
return message.channel.send(sayMessage);
}
else {
return message.channel.send("Im sorry but we cant have nice things...")
}
}