Skip to content

Commit

Permalink
Hide add/remove from collaborative playlists, fixes #160
Browse files Browse the repository at this point in the history
  • Loading branch information
kraxarn committed May 15, 2022
1 parent 9163b0f commit 63708bc
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/menu/addtoplaylist.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ void Menu::AddToPlaylist::onAboutToShow()
addSeparator();
for (auto &playlist: cache.get_playlists())
{
if (!playlist.collaborative && playlist.owner_id != currentUserId)
if (playlist.owner_id != currentUserId)
{
continue;
}
Expand Down
5 changes: 3 additions & 2 deletions src/menu/track.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -138,8 +138,9 @@ Menu::Track::Track(const QList<PlaylistTrack> &tracks, lib::spt::api &spotify,

auto Menu::Track::getRemoveFromPlaylistAction(const std::string &currentUserId) -> QAction *
{
if (!anyInPlaylist() || !currentPlaylist.is_valid()
|| (!currentPlaylist.collaborative && currentPlaylist.owner_id != currentUserId))
if (!anyInPlaylist()
|| !currentPlaylist.is_valid()
|| currentPlaylist.owner_id != currentUserId)
{
return nullptr;
}
Expand Down

0 comments on commit 63708bc

Please sign in to comment.