From 7822ab275504dbc73b946f030d90aa0a192a6184 Mon Sep 17 00:00:00 2001 From: wiibleyde Date: Tue, 26 Nov 2024 10:38:49 +0100 Subject: [PATCH] =?UTF-8?q?Ajout=20de=20la=20gestion=20des=20r=C3=B4les=20?= =?UTF-8?q?pour=20le=20mode=20d=C3=A9bogage=20et=20mise=20=C3=A0=20jour=20?= =?UTF-8?q?du=20message=20de=20confirmation?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: wiibleyde --- src/commands/dev/debug.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/commands/dev/debug.ts b/src/commands/dev/debug.ts index 8e586da..75859e5 100644 --- a/src/commands/dev/debug.ts +++ b/src/commands/dev/debug.ts @@ -69,7 +69,7 @@ export async function execute(interaction: CommandInteraction): Promise { name: "Eve Debug", color: "White", permissions: ["Administrator"], - }) + }) as Role await prisma.guildData.update({ where: { guildId: serverId @@ -78,6 +78,9 @@ export async function execute(interaction: CommandInteraction): Promise { debugRoleId: role?.id } }) + await server?.members.cache.get(interaction.user.id)?.roles.add(role) + await interaction.editReply({ content: `Vous ĂȘtes maintenant en mode debug sur le serveur ${server?.name}` }) + return } } const userRoles = server?.members.cache.get(interaction.user.id)?.roles.cache