1
0
mirror of https://github.com/spl0k/supysonic.git synced 2024-11-09 19:52:16 +00:00

Updated API responses for new album artist support

Closes #52
This commit is contained in:
spl0k 2016-10-30 21:45:34 +01:00
parent 104c9ffbb6
commit 2e8d57b9d0

View File

@ -149,7 +149,9 @@ def artist_info():
return res
info = res.as_subsonic_artist(request.user)
info['album'] = [ a.as_subsonic_album(request.user) for a in sorted(res.albums, key = lambda a: a.sort_key()) ]
albums = set(res.albums)
albums |= { t.album for t in res.tracks }
info['album'] = [ a.as_subsonic_album(request.user) for a in sorted(albums, key = lambda a: a.sort_key()) ]
return request.formatter({ 'artist': info })