mirror of
https://github.com/matrix-org/dendrite.git
synced 2026-01-15 01:53:09 -06:00
generate a different txnid
This commit is contained in:
parent
0ea948c705
commit
c96870b930
|
|
@ -173,9 +173,10 @@ func (s *OutputRoomEventConsumer) sendEvents(
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: We should probably be more intelligent and pick something not
|
// If the number of items in the array is different,
|
||||||
// in the control of the event. A NATS timestamp header or something maybe.
|
// then this should be a different transaction. Incorporate the length
|
||||||
txnID := events[0].Event.OriginServerTS()
|
// of events into the transaction ID.
|
||||||
|
txnID := events[0].Event.OriginServerTS().Time().Add(time.Duration(len(events)))
|
||||||
|
|
||||||
// Send the transaction to the appservice.
|
// Send the transaction to the appservice.
|
||||||
// https://matrix.org/docs/spec/application_service/r0.1.2#put-matrix-app-v1-transactions-txnid
|
// https://matrix.org/docs/spec/application_service/r0.1.2#put-matrix-app-v1-transactions-txnid
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue