mirror of
https://github.com/Dvorinka/swingmusic-extended.git
synced 2026-06-03 20:13:02 +00:00
fix: bottom bar fav button bug
~ bug caused by toggling and untoggling the fav state
This commit is contained in:
committed by
Mungai Njoroge
parent
0f0f0e0762
commit
6095c9fa8f
@@ -89,8 +89,8 @@ function handleFav() {
|
||||
queue.currenttrack?.is_favorite,
|
||||
favType.track,
|
||||
queue.currenttrack?.trackhash || "",
|
||||
() => queue.toggleFav(queue.currentindex),
|
||||
() => queue.toggleFav(queue.currentindex)
|
||||
() => null,
|
||||
() => null
|
||||
);
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -23,7 +23,7 @@ async function createNewPlaylist(playlist_name: string, track?: Track) {
|
||||
});
|
||||
|
||||
if (status == 201) {
|
||||
new Notification("✅ Playlist created successfullly!");
|
||||
new Notification("Playlist created successfullly!");
|
||||
|
||||
if (track) {
|
||||
setTimeout(() => {
|
||||
@@ -75,11 +75,11 @@ async function addTrackToPlaylist(playlist: Playlist, track: Track) {
|
||||
});
|
||||
|
||||
if (status == 409) {
|
||||
new Notification("Track already exists in playlist", NotifType.Info);
|
||||
new Notification("Track already exists in playlist");
|
||||
return;
|
||||
}
|
||||
|
||||
new Notification(track.title + " added to " + playlist.name);
|
||||
new Notification(track.title + " added to " + playlist.name, NotifType.Success);
|
||||
}
|
||||
|
||||
async function getPlaylist(pid: string) {
|
||||
|
||||
Reference in New Issue
Block a user