From 6e48a83d109faa1b946877728692549dd7364ece Mon Sep 17 00:00:00 2001 From: Marius Begby Date: Sun, 9 Jul 2023 13:55:22 +0200 Subject: [PATCH] Update interaction editReply --- commands/filters.js | 6 +++--- commands/leave.js | 4 ++-- commands/pause.js | 2 +- commands/play.js | 4 ++-- commands/queue.js | 6 +++--- commands/remove.js | 2 +- commands/skip.js | 2 +- commands/volume.js | 2 +- 8 files changed, 14 insertions(+), 14 deletions(-) diff --git a/commands/filters.js b/commands/filters.js index c3a4482..4872635 100644 --- a/commands/filters.js +++ b/commands/filters.js @@ -19,7 +19,7 @@ module.exports = { .setDescription('Toggle various audio filters during playback.'), run: async ({ interaction }) => { if (!interaction.member.voice.channel) { - return interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setDescription( @@ -140,7 +140,7 @@ module.exports = { // Enable provided filters queue.filters.ffmpeg.toggle(confirmation.values); - await interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setAuthor({ @@ -166,7 +166,7 @@ module.exports = { }); } catch (e) { console.log(e); - await interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setDescription( diff --git a/commands/leave.js b/commands/leave.js index 989d8ad..dee7d73 100644 --- a/commands/leave.js +++ b/commands/leave.js @@ -13,7 +13,7 @@ module.exports = { // todo, allow command to be executed if bot is only member in voice channel run: async ({ interaction }) => { if (!interaction.member.voice.channel) { - return interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setDescription( @@ -41,7 +41,7 @@ module.exports = { if (!queue.deleted) { queue.delete(); - await interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setDescription( diff --git a/commands/pause.js b/commands/pause.js index 506edb6..18ce475 100644 --- a/commands/pause.js +++ b/commands/pause.js @@ -9,7 +9,7 @@ module.exports = { .setDescription('Pause the currently playing track.'), run: async ({ interaction }) => { if (!interaction.member.voice.channel) { - return interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setDescription( diff --git a/commands/play.js b/commands/play.js index 3aef33d..2559607 100644 --- a/commands/play.js +++ b/commands/play.js @@ -15,7 +15,7 @@ module.exports = { ), run: async ({ interaction }) => { if (!interaction.member.voice.channel) { - return interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setDescription( @@ -59,7 +59,7 @@ module.exports = { // TODO: Add a check to see if the queue is empty, and if so, add a message to the embed saying that the track is now playing. // TODO: YouTube thumbnail not shown? Different url than track.thumbnail? - await interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setAuthor({ diff --git a/commands/queue.js b/commands/queue.js index b5dedab..d22598f 100644 --- a/commands/queue.js +++ b/commands/queue.js @@ -15,7 +15,7 @@ module.exports = { ), run: async ({ interaction }) => { if (!interaction.member.voice.channel) { - return interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setDescription( @@ -75,7 +75,7 @@ module.exports = { let currentTrack = queue.currentTrack; if (!currentTrack) { - await interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setAuthor({ @@ -95,7 +95,7 @@ module.exports = { length: 13 }); - await interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setAuthor({ diff --git a/commands/remove.js b/commands/remove.js index bbbed7a..b830144 100644 --- a/commands/remove.js +++ b/commands/remove.js @@ -16,7 +16,7 @@ module.exports = { ), run: async ({ interaction }) => { if (!interaction.member.voice.channel) { - return interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setDescription( diff --git a/commands/skip.js b/commands/skip.js index e4b34cc..88360f2 100644 --- a/commands/skip.js +++ b/commands/skip.js @@ -17,7 +17,7 @@ module.exports = { ), run: async ({ interaction }) => { if (!interaction.member.voice.channel) { - return interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setDescription( diff --git a/commands/volume.js b/commands/volume.js index d75ed20..f43f919 100644 --- a/commands/volume.js +++ b/commands/volume.js @@ -16,7 +16,7 @@ module.exports = { ), run: async ({ interaction }) => { if (!interaction.member.voice.channel) { - return interaction.editReply({ + return await interaction.editReply({ embeds: [ new EmbedBuilder() .setDescription(