From d24f7562bb423972aa25efa8a10c9bb2b62d5166 Mon Sep 17 00:00:00 2001 From: hwangsihu Date: Sat, 19 Oct 2024 08:49:01 +0900 Subject: [PATCH] Changed command log to embedd --- src/events/client/InteractionCreate.ts | 10 +++++----- src/events/client/MessageCreate.ts | 6 ++++-- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/events/client/InteractionCreate.ts b/src/events/client/InteractionCreate.ts index 3a1abdd50..7a9fdcd5a 100644 --- a/src/events/client/InteractionCreate.ts +++ b/src/events/client/InteractionCreate.ts @@ -240,13 +240,13 @@ export default class InteractionCreate extends Event { const embed = new EmbedBuilder() .setAuthor({ name: 'Slash - Command Logs', - iconURL: this.client.user?.avatarURL({ - size: 2048, - })!, + iconURL: this.client.user?.avatarURL({ size: 2048 })!, }) .setColor(this.client.config.color.blue) - .setDescription( - `**\`${command.name}\`** | Used By **${interaction.user.tag} \`${interaction.user.id}\`** From **${interaction.guild.name} \`${interaction.guild.id}\`**`, + .addFields( + { name: 'Command', value: `\`${command.name}\``, inline: true }, + { name: 'User', value: `${interaction.user.tag} (\`${interaction.user.id}\`)`, inline: true }, + { name: 'Guild', value: `${interaction.guild.name} (\`${interaction.guild.id}\`)`, inline: true }, ) .setTimestamp(); diff --git a/src/events/client/MessageCreate.ts b/src/events/client/MessageCreate.ts index ef36a26d4..b58e9e77d 100644 --- a/src/events/client/MessageCreate.ts +++ b/src/events/client/MessageCreate.ts @@ -259,8 +259,10 @@ export default class MessageCreate extends Event { iconURL: this.client.user?.avatarURL({ size: 2048 })!, }) .setColor(this.client.config.color.green) - .setDescription( - `**\`${command.name}\`** | Used By **${message.author.tag} \`${message.author.id}\`** From **${message.guild.name} \`${message.guild.id}\`**`, + .addFields( + { name: 'Command', value: `\`${command.name}\``, inline: true }, + { name: 'User', value: `${message.author.tag} (\`${message.author.id}\`)`, inline: true }, + { name: 'Guild', value: `${message.guild.name} (\`${message.guild.id}\`)`, inline: true }, ) .setTimestamp();