mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-13 01:43:09 -06:00
Comments
This commit is contained in:
parent
2316f399c7
commit
64ed0b90c5
|
|
@ -137,6 +137,8 @@ func (s *OutputRoomEvent) processMessage(ore api.OutputNewRoomEvent) error {
|
||||||
if oldJoinedHosts == nil {
|
if oldJoinedHosts == nil {
|
||||||
// This means that there is nothing to update as this is a duplicate
|
// This means that there is nothing to update as this is a duplicate
|
||||||
// message.
|
// message.
|
||||||
|
// This can happen if dendrite crashed between reading the message and
|
||||||
|
// persisting the stream position.
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -84,7 +84,9 @@ func (d *Database) UpdateRoom(
|
||||||
}
|
}
|
||||||
|
|
||||||
if lastSentEventID == newEventID {
|
if lastSentEventID == newEventID {
|
||||||
// We've handled this messages before, so lets just ignore it
|
// We've handled this message before, so let's just ignore it.
|
||||||
|
// We can only get a duplicate for the last message we processed,
|
||||||
|
// so its enough just to compare the newEventID with lastSentEventID
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue