mirror of
https://github.com/darksaid98/cadence-discord-bot.git
synced 2026-12-04 14:38:49 +00:00
fix: Fix playlist added position being incorrect in some cases
This commit is contained in:
1 parent
30abb470b9
commit
664fa50dfe
1 file changed
+2
-4
@@ -188,10 +188,8 @@ class PlayCommand extends BaseSlashCommandInteraction {
|
|||||||
count: searchResult.tracks.length,
|
count: searchResult.tracks.length,
|
||||||
queueCommand: formatSlashCommand('queue', translator)
|
queueCommand: formatSlashCommand('queue', translator)
|
||||||
});
|
});
|
||||||
if (queue.tracks.data.length != searchResult.tracks.length) {
|
const posistionFirstTrackInPlaylist = queue.tracks.data.length - searchResult.tracks.length + 1;
|
||||||
const posistionFirstTrackInPlaylist = queue.tracks.data.length - searchResult.tracks.length + 1;
|
embedFooter = this.getDisplayFooterTrackPosition(posistionFirstTrackInPlaylist, translator);
|
||||||
embedFooter = this.getDisplayFooterTrackPosition(posistionFirstTrackInPlaylist, translator);
|
|
||||||
}
|
|
||||||
} else if (queue.currentTrack === track && queue.tracks.data.length === 0) {
|
} else if (queue.currentTrack === track && queue.tracks.data.length === 0) {
|
||||||
if (!this.embedOptions.behavior.enablePlayerStartMessages) {
|
if (!this.embedOptions.behavior.enablePlayerStartMessages) {
|
||||||
message =
|
message =
|
||||||
|
|||||||
Reference in new issue
Block a user