volumio / Volumio2

Volumio 2 - Audiophile Music Player
http://volumio.org
Other
1.37k stars 315 forks source link

Delete from Playlist with track coming from youtube2 or spotify #2154

Open barais opened 3 years ago

barais commented 3 years ago

It seems that there is an issue on removing an element from playlist see [1,2].

The service name is not the correct one. A solution could be to change a bit this line.

https://github.com/volumio/Volumio2/blob/6f8166e15dcfc583df8fe48d7065992c799d18bb/app/playlistManager.js#L657

to

        if (/*data[i].service == service && */ data[i].uri == uri) {

in function commonRemoveFromPlaylist. For me, if the item has the right uri in a playlist, you could probably remove the test on the service namebut I'm probably missing something. The real bug is probably in the user interface. (Anyway, for items coming from youtube2 or spotify, the service names do not match 'mpd vs spot'

[1] https://community.volumio.org/t/volumio-playlist-remove-from-playlist-not-working/38982/3 [2] https://community.volumio.org/t/delete-from-playlist-does-not-work/9899/3

patrickkfkan commented 3 years ago

The real culprit is in https://github.com/volumio/Volumio2/blob/fd3e37ffec12db034ec93f94dbc26e5495d5b91a/app/plugins/user_interface/websocket/index.js#L540

I pointed this out back in April: https://community.volumio.org/t/removing-playlists/46895/4

Still hasn't been fixed, so I've created a PR for this.