This commit is contained in:
Erik Johnston 2017-10-12 09:36:11 +01:00
parent 2316f399c7
commit 64ed0b90c5
2 changed files with 5 additions and 1 deletions

View file

@ -137,6 +137,8 @@ func (s *OutputRoomEvent) processMessage(ore api.OutputNewRoomEvent) error {
if oldJoinedHosts == nil {
// This means that there is nothing to update as this is a duplicate
// message.
// This can happen if dendrite crashed between reading the message and
// persisting the stream position.
return nil
}

View file

@ -84,7 +84,9 @@ func (d *Database) UpdateRoom(
}
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
}