From 75a3b3b52d3f0dfabb0a3a16f90f96702d3e0bec Mon Sep 17 00:00:00 2001 From: VinceC <33974776+VinceC3@users.noreply.github.com> Date: Wed, 1 Jan 2025 10:05:05 -0600 Subject: [PATCH] show when stats are requested --- src/Bot.js | 8 +++++--- src/commands/CommandHandler.js | 4 ---- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/src/Bot.js b/src/Bot.js index a531c5c..6cf4428 100644 --- a/src/Bot.js +++ b/src/Bot.js @@ -73,10 +73,12 @@ class Bot { try { if (interaction.isCommand()) { - // Send immediate acknowledgment - await interaction.deferReply({ ephemeral: true }); + // Remove ephemeral flag for finduser and matchhistory commands + const isStatsCommand = ['finduser', 'matchhistory'].includes(interaction.commandName); + await interaction.deferReply({ + ephemeral: !isStatsCommand + }); - // Process command asynchronously this.logger.debug('Processing command', { command: interaction.commandName, guild: interaction.guild?.name, diff --git a/src/commands/CommandHandler.js b/src/commands/CommandHandler.js index 716b6ea..756f4a1 100644 --- a/src/commands/CommandHandler.js +++ b/src/commands/CommandHandler.js @@ -152,7 +152,6 @@ class CommandHandler { if (!userData || !userData.success) { await interaction.editReply({ content: '❌ User not found or an error occurred while fetching data.', - ephemeral: true }); return; } @@ -167,7 +166,6 @@ class CommandHandler { await interaction.editReply({ embeds: [embed], components: [row], - ephemeral: true }); } catch (error) { this.logger.error('Error in handleFindUser:', { @@ -188,7 +186,6 @@ class CommandHandler { if (!userData || !userData.success) { await interaction.editReply({ content: '❌ User not found or an error occurred while fetching data.', - ephemeral: true }); return; } @@ -209,7 +206,6 @@ class CommandHandler { await interaction.editReply({ embeds: [embed], components: [row], - ephemeral: true }); } catch (error) { this.logger.error('Error in handleMatchHistory:', {