1
0
mirror of https://github.com/spl0k/supysonic.git synced 2024-12-22 17:06:17 +00:00

B"H allow accessing public playlists even when not admin

This commit is contained in:
hhm 2018-03-21 23:11:28 -04:00
parent 98a0deb2d0
commit 6bb98085bc

View File

@ -37,7 +37,7 @@ def list_playlists():
@api.route('/getPlaylist.view', methods = [ 'GET', 'POST' ])
def show_playlist():
res = get_entity(Playlist)
if res.user.id != request.user.id and not request.user.admin:
if res.user.id != request.user.id and not res.public and not request.user.admin:
raise Forbidden()
info = res.as_subsonic_playlist(request.user)