mirror of
https://code.eliotberriot.com/funkwhale/funkwhale.git
synced 2025-10-05 04:29:23 +02:00
See #170: channels ui (listeners)
This commit is contained in:
parent
b74517ff33
commit
95497e76ac
79 changed files with 1768 additions and 232 deletions
|
@ -156,6 +156,19 @@ def serialize_artist_simple(artist):
|
|||
else None
|
||||
)
|
||||
|
||||
if "attachment_cover" in artist._state.fields_cache:
|
||||
data["cover"] = (
|
||||
cover_field.to_representation(artist.attachment_cover)
|
||||
if artist.attachment_cover
|
||||
else None
|
||||
)
|
||||
|
||||
if getattr(artist, "_tracks_count", None) is not None:
|
||||
data["tracks_count"] = artist._tracks_count
|
||||
|
||||
if getattr(artist, "_prefetched_tagged_items", None) is not None:
|
||||
data["tags"] = [ti.tag.name for ti in artist._prefetched_tagged_items]
|
||||
|
||||
return data
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue