Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] $queue - incorrect position index of current track playing #11

Closed
AstrooKai opened this issue Jan 29, 2024 · 1 comment
Closed
Assignees
Labels
bug Something isn't working

Comments

@AstrooKai
Copy link

Current Behavior

The position of the current track playing is displayed incorrectly. There are instances where the position of the playing track is 0 and sometimes 1. When the playing track is displayed as 1, the position of the next track in the queue remains 1, causing a double 1 in the queue list.

Expected Behavior

The position of the current track playing should be displayed as 1 in the long queue list with the correct position numbers for the following tracks in the queue.

Steps To Reproduce

Reproduce where the current track playing is displayed as 0

$queue[1;10;**{position}.** {title} - {artist}\nRequested by: {requester.user.username}\n]

Reproduce where the current track playing is displayed as 1, but the next track remains 1

$queue[1;10;{position}. {title} - {artist}\nRequested by: {requester.user.username}\n]

It's unclear and confusing how increasing the font weight of the {position} alters its behavior.

Environment

Environment: Visual Studio Code (v1.85.2)
NodeJS: v21.5.0
AoiJS: v6.7.1

Anything else?

It would also be a convenience to remove the comma (,) at the beginning of the position since it requires additional functions (e.g. $replaceText) to remove this, but doing so may also remove the commas that are in the titles or authors since wrapping the {position} inside the function doesn't work as intended (the {position} doesn't get parsed first before being evaluated for text replacement).

@AstrooKai AstrooKai added the bug Something isn't working label Jan 29, 2024
@Faf4a
Copy link
Member

Faf4a commented May 16, 2024

It's a little confusing but,

when the queue length is below 1 it takes 0 as current, if its above it takes 1 as current and 0 as previous

@Faf4a Faf4a closed this as not planned Won't fix, can't repro, duplicate, stale Jul 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants