From 9f1ac379276c11da65235577a9c6717e01cb02eb Mon Sep 17 00:00:00 2001 From: PalmDevs Date: Fri, 29 Mar 2024 17:25:36 +0700 Subject: [PATCH] feat(bots/discord/commands/reply): send stacktrace when failed --- bots/discord/src/commands/reply.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bots/discord/src/commands/reply.ts b/bots/discord/src/commands/reply.ts index b73e1c2..a5fe0b2 100644 --- a/bots/discord/src/commands/reply.ts +++ b/bots/discord/src/commands/reply.ts @@ -1,3 +1,4 @@ +import { createStackTraceEmbed } from '$/utils/discord/embeds' import { PermissionFlagsBits, SlashCommandBuilder, type TextBasedChannel } from 'discord.js' import type { Command } from '.' @@ -48,7 +49,9 @@ export default { ephemeral: true, }) } catch (e) { - await interaction.reply({}) + await interaction.reply({ + embeds: [createStackTraceEmbed(e)], + }) } }, } satisfies Command