diff options
author | Neil Alexander <neilalexander@users.noreply.github.com> | 2020-02-28 14:54:51 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-02-28 14:54:51 +0000 |
commit | 6460b3725d1d468c8f3353b99797661cfaf539e3 (patch) | |
tree | 5ff918534eb6f059f5d4f262f3848015937be001 | |
parent | 420ee15433aa2adcbc020875003c3d15c067b03e (diff) |
Make sure PDUs and EDUs in transaction don't marshal to null (#876)
-rw-r--r-- | federationsender/queue/destinationqueue.go | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/federationsender/queue/destinationqueue.go b/federationsender/queue/destinationqueue.go index c0afe3be..f412cb19 100644 --- a/federationsender/queue/destinationqueue.go +++ b/federationsender/queue/destinationqueue.go @@ -102,7 +102,10 @@ func (oq *destinationQueue) next() *gomatrixserverlib.Transaction { return nil } - var t gomatrixserverlib.Transaction + t := gomatrixserverlib.Transaction{ + PDUs: []gomatrixserverlib.Event{}, + EDUs: []gomatrixserverlib.EDU{}, + } now := gomatrixserverlib.AsTimestamp(time.Now()) t.TransactionID = gomatrixserverlib.TransactionID(fmt.Sprintf("%d-%d", now, oq.sentCounter)) t.Origin = oq.origin |