From e9c0b6e3a956c4890ee534fa043c387e3e87e529 Mon Sep 17 00:00:00 2001 From: cubicroot Date: Fri, 8 Apr 2022 20:14:22 +0200 Subject: [PATCH] fix empty notifications --- internal/dispatcher/notification.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/dispatcher/notification.go b/internal/dispatcher/notification.go index b23bca6..29d3bf9 100644 --- a/internal/dispatcher/notification.go +++ b/internal/dispatcher/notification.go @@ -33,7 +33,7 @@ type MessageEvent struct { MsgType MsgType `json:"msgtype"` RelatesTo RelatesTo `json:"m.relates_to,omitempty"` Format MessageFormat `json:"format"` - NewContent NewContent `json:"m.new_content,omitempty"` + NewContent *NewContent `json:"m.new_content,omitempty"` } // RelatesTo holds information about relations to other message events @@ -212,7 +212,7 @@ func (d *Dispatcher) replaceMessage(a *model.Application, newBody, newFormattedB Body: oldBody, FormattedBody: oldFormattedBody, MsgType: MsgTypeText, - NewContent: newMessage, + NewContent: &newMessage, RelatesTo: replaceRelation, Format: MessageFormatHTML, }