correction confession

This commit is contained in:
VALOU3336
2024-02-27 17:16:42 +01:00
parent 74df746b53
commit 51c3ce5880
2 changed files with 7 additions and 13 deletions
+3 -1
View File
@@ -4,6 +4,9 @@ const { ActionRowBuilder, ButtonStyle, EmbedBuilder, ButtonBuilder} = require('d
module.exports = {
name: 'confession',
description: 'Configure les paramètres pour le salon de confession.',
category: 'gestion',
emote: '🙏',
usage: 'confession [channel|send] [channelID|#channel]',
async execute(message, args) {
const guildId = message.guild.id;
if (!args.length) return message.reply('Veuillez spécifier une sous-commande: channel ou send.');
@@ -37,7 +40,6 @@ async function setConfessionChannel(guildId, message, channelInput) {
channelId = channelInput;
}
// Vérifier si le salon existe
const channel = message.guild.channels.cache.get(channelId);
if (!channel) {
return message.reply('Le salon spécifié n\'existe pas ou l\'ID est incorrect.');