From e4b441e5f51fd58ee86094c6fed5a031540de22e Mon Sep 17 00:00:00 2001 From: Supositware Date: Sun, 4 Feb 2024 17:36:42 +0100 Subject: [PATCH] Fix "thinking" message not getting deleted --- commands/utility/download.js | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/commands/utility/download.js b/commands/utility/download.js index 604a110e..57661b97 100644 --- a/commands/utility/download.js +++ b/commands/utility/download.js @@ -163,7 +163,10 @@ async function download(url, interaction, originalInteraction, format = undefine if (interactionMenu.customId === `preset${interaction.user.id}${interaction.id}`) { await interactionMenu.deferReply({ ephemeral: false }); compress(file, interactionMenu, Embed); - if (interaction.isMessage) interaction.cleanUp(); + if (interaction.isMessage) { + interaction.deleteReply(); + interaction.cleanUp(); + } } }); return; @@ -216,7 +219,10 @@ async function download(url, interaction, originalInteraction, format = undefine await interaction.editReply({ embeds: [Embed], files: [output], ephemeral: false }); } - if (interaction.isMessage) interaction.cleanUp(); + if (interaction.isMessage) { + interaction.deleteReply(); + interaction.cleanUp(); + } }) .catch(async err => { console.error(err);