This commit is contained in:
Daniel Odendahl Jr
2017-10-06 13:46:37 +00:00
parent 6f3677b8ee
commit e81226dbd6
+1 -1
View File
@@ -8,7 +8,7 @@ class EmojiArgumentType extends ArgumentType {
validate(value, msg) {
const matches = value.match(/^(?:<:([a-zA-Z0-9_]+):)?([0-9]+)>?$/);
if (msg.client.emojis.has(matches[2])) return true;
if (matches && msg.client.emojis.has(matches[2])) return true;
if (!msg.guild) return false;
const search = value.toLowerCase();
let emojis = msg.guild.emojis.filterArray(nameFilterInexact(search));