Skip to content

Commit

Permalink
Fix not being able to view different queue pages
Browse files Browse the repository at this point in the history
  • Loading branch information
CyberedCake committed Feb 4, 2024
1 parent 67ac249 commit c762228
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ private void handleQueueCMD(IReplyCallback callback, int page) {
if (musicPlayer == null) return;

this.currentTrackIndex = musicPlayer.getTrackScheduler().getQueue().getCurrentIndex();
if (page != -1)
if (page == -1)
page = getPageOf(currentTrackIndex);

int maxPages = getMaxPages(callback.getGuild());
Expand Down Expand Up @@ -133,7 +133,7 @@ private String nextLineFormatting(MusicPlayer musicPlayer, AudioTrack track, @Nu
public void viewQueue(ButtonInteractionEvent event) {
event.deferReply().setEphemeral(true).queue();

handleQueueCMD(event, 1);
handleQueueCMD(event, -1);
}

@Override
Expand Down

0 comments on commit c762228

Please sign in to comment.