|
@@ -100,13 +100,13 @@ const commands = {
|
|
|
const pattern = /^react to\s+"([^"]+)"\s+with\s+\<:[^:]+:([^\>]+)\>$/i;
|
|
|
let contents = pattern.exec(s);
|
|
|
if(contents != null) {
|
|
|
- let reactable = contents[1];
|
|
|
+ let reactable = contents[1].trim().toLowerCase();
|
|
|
let reactionEmoji = contents[2];
|
|
|
if(!client.emojis.has(reactionEmoji)){
|
|
|
msg.channel.send(`${msg.author.toString()} I cannot react with this emoji :(`);
|
|
|
return;
|
|
|
}
|
|
|
- db.get("messageReactions").set(reactable.toLowerCase(), reactionEmoji).write();
|
|
|
+ db.get("messageReactions").set(reactable, reactionEmoji).write();
|
|
|
msg.channel.send(`${msg.author.toString()} Added reaction!`);
|
|
|
}
|
|
|
},
|