Handle API identities with no name
This commit is contained in:
parent
c0cd5a5553
commit
faca9224ed
@ -505,10 +505,10 @@ class Identity(StatorModel):
|
|||||||
)
|
)
|
||||||
return {
|
return {
|
||||||
"id": self.pk,
|
"id": self.pk,
|
||||||
"username": self.username,
|
"username": self.username or "",
|
||||||
"acct": self.username if self.local else self.handle,
|
"acct": self.username if self.local else self.handle,
|
||||||
"url": self.absolute_profile_uri(),
|
"url": self.absolute_profile_uri(),
|
||||||
"display_name": self.name,
|
"display_name": self.name or "",
|
||||||
"note": self.summary or "",
|
"note": self.summary or "",
|
||||||
"avatar": self.local_icon_url().absolute,
|
"avatar": self.local_icon_url().absolute,
|
||||||
"avatar_static": self.local_icon_url().absolute,
|
"avatar_static": self.local_icon_url().absolute,
|
||||||
|
Reference in New Issue
Block a user