From 9136500baa80530e0cce55d17b3bc1e8f263e999 Mon Sep 17 00:00:00 2001 From: JonnyBro Date: Fri, 26 Aug 2022 22:23:27 +0500 Subject: [PATCH] =?UTF-8?q?=D0=94=D0=B8=D0=BD=D0=B0=D0=BC=D0=B8=D1=87?= =?UTF-8?q?=D0=B5=D1=81=D0=BA=D0=BE=D0=B5=20=D0=BE=D0=B1=D0=BD=D0=BE=D0=B2?= =?UTF-8?q?=D0=BB=D0=B5=D0=BD=D0=B8=D0=B5=20=D0=BE=D1=87=D0=B5=D1=80=D0=B5?= =?UTF-8?q?=D0=B4=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- commands/Music/queue.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/commands/Music/queue.js b/commands/Music/queue.js index b77d30d8..019d91bf 100644 --- a/commands/Music/queue.js +++ b/commands/Music/queue.js @@ -35,7 +35,7 @@ class Queue extends BaseCommand { if (!queue) return interaction.error("music/play:NOT_PLAYING"); let currentPage = 0; - const embeds = generateQueueEmbed(interaction, queue); + let embeds = generateQueueEmbed(interaction, queue); const row = new ActionRowBuilder() .addComponents( @@ -77,6 +77,7 @@ class Queue extends BaseCommand { if (i.isButton()) { if (i.customId === "queue_prev_page") { i.deferUpdate(); + if (embeds != generateQueueEmbed(interaction, queue)) embeds = generateQueueEmbed(interaction, queue); if (currentPage !== 0) { --currentPage; @@ -91,6 +92,7 @@ class Queue extends BaseCommand { } } else if (i.customId === "queue_next_page") { i.deferUpdate(); + if (embeds != generateQueueEmbed(interaction, queue)) embeds = generateQueueEmbed(interaction, queue); if (currentPage < embeds.length - 1) { currentPage++; @@ -105,6 +107,7 @@ class Queue extends BaseCommand { } } else if (i.customId === "queue_jump_page") { i.deferUpdate(); + if (embeds != generateQueueEmbed(interaction, queue)) embeds = generateQueueEmbed(interaction, queue); const msg = await interaction.followUp({ content: interaction.translate("music/queue:PAGE_TO_JUMP", {