mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-03 23:36:43 +02:00
Require manage emojis permission in emoji
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
"VIEW_AUDIT_LOG",
|
||||
"VIEW_CHANNEL",
|
||||
"SEND_MESSAGES",
|
||||
"MANAGE_EMOJIS",
|
||||
"MANAGE_MESSAGES",
|
||||
"EMBED_LINKS",
|
||||
"ATTACH_FILES",
|
||||
|
||||
@@ -11,7 +11,7 @@ module.exports = class EmojiCommand extends Command {
|
||||
memberName: 'emoji',
|
||||
description: 'Responds with detailed information on an emoji.',
|
||||
guildOnly: true,
|
||||
clientPermissions: ['EMBED_LINKS'],
|
||||
clientPermissions: ['EMBED_LINKS', 'MANAGE_EMOJIS'],
|
||||
args: [
|
||||
{
|
||||
key: 'emoji',
|
||||
@@ -23,7 +23,7 @@ module.exports = class EmojiCommand extends Command {
|
||||
}
|
||||
|
||||
async run(msg, { emoji }) {
|
||||
if (!emoji.author) await emoji.fetchAuthor();
|
||||
if (!emoji.author && !emoji.managed) await emoji.fetchAuthor();
|
||||
const embed = new MessageEmbed()
|
||||
.setColor(0x00AE86)
|
||||
.setThumbnail(emoji.url)
|
||||
|
||||
Reference in New Issue
Block a user