summaryrefslogtreecommitdiff
path: root/internal
diff options
context:
space:
mode:
authorLibravatar Vyr Cossont <VyrCossont@users.noreply.github.com>2024-07-24 01:40:01 -0700
committerLibravatar GitHub <noreply@github.com>2024-07-24 10:40:01 +0200
commitdb0a47126eb1b960c86fff071e968834c098a1a3 (patch)
tree734ba8ee5bc910123c5f411c52b0d28f32108a62 /internal
parent[chore] Add some log lines to recent migrations warning not to interrupt (#3134) (diff)
downloadgotosocial-db0a47126eb1b960c86fff071e968834c098a1a3.tar.xz
[bugfix] Serialize empty conversation account list as empty list, not null (#3137)
Diffstat (limited to 'internal')
-rw-r--r--internal/typeutils/internaltofrontend.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/internal/typeutils/internaltofrontend.go b/internal/typeutils/internaltofrontend.go
index c194360c1..29d972e48 100644
--- a/internal/typeutils/internaltofrontend.go
+++ b/internal/typeutils/internaltofrontend.go
@@ -1752,8 +1752,9 @@ func (c *Converter) ConversationToAPIConversation(
mutes *usermute.CompiledUserMuteList,
) (*apimodel.Conversation, error) {
apiConversation := &apimodel.Conversation{
- ID: conversation.ID,
- Unread: !*conversation.Read,
+ ID: conversation.ID,
+ Unread: !*conversation.Read,
+ Accounts: []apimodel.Account{},
}
for _, account := range conversation.OtherAccounts {
var apiAccount *apimodel.Account