mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2024-11-25 05:06:38 +00:00
[bugfix] Serialize empty conversation account list as empty list, not null (#3137)
This commit is contained in:
parent
6533531cf1
commit
db0a47126e
|
@ -1752,8 +1752,9 @@ func (c *Converter) ConversationToAPIConversation(
|
||||||
mutes *usermute.CompiledUserMuteList,
|
mutes *usermute.CompiledUserMuteList,
|
||||||
) (*apimodel.Conversation, error) {
|
) (*apimodel.Conversation, error) {
|
||||||
apiConversation := &apimodel.Conversation{
|
apiConversation := &apimodel.Conversation{
|
||||||
ID: conversation.ID,
|
ID: conversation.ID,
|
||||||
Unread: !*conversation.Read,
|
Unread: !*conversation.Read,
|
||||||
|
Accounts: []apimodel.Account{},
|
||||||
}
|
}
|
||||||
for _, account := range conversation.OtherAccounts {
|
for _, account := range conversation.OtherAccounts {
|
||||||
var apiAccount *apimodel.Account
|
var apiAccount *apimodel.Account
|
||||||
|
|
Loading…
Reference in a new issue