Don't block AS transaction processing on read receipts
This commit is contained in:
parent
500f030fb3
commit
ed00d333d1
1 changed files with 8 additions and 6 deletions
14
portal.go
14
portal.go
|
@ -2003,12 +2003,14 @@ func (portal *Portal) HandleMatrixReadReceipt(brUser bridge.User, eventID id.Eve
|
||||||
targetMessage = lastMessage
|
targetMessage = lastMessage
|
||||||
}
|
}
|
||||||
log = log.With().Str("message_id", targetMessage.ID).Logger()
|
log = log.With().Str("message_id", targetMessage.ID).Logger()
|
||||||
err = user.Client.MarkRead(portal.ID, targetMessage.ID)
|
go func() {
|
||||||
if err != nil {
|
err = user.Client.MarkRead(portal.ID, targetMessage.ID)
|
||||||
log.Err(err).Msg("Failed to mark message as read")
|
if err != nil {
|
||||||
} else {
|
log.Err(err).Msg("Failed to mark message as read")
|
||||||
log.Debug().Msg("Marked message as read after Matrix read receipt")
|
} else {
|
||||||
}
|
log.Debug().Msg("Marked message as read after Matrix read receipt")
|
||||||
|
}
|
||||||
|
}()
|
||||||
}
|
}
|
||||||
|
|
||||||
func (portal *Portal) HandleMatrixReaction(sender *User, evt *event.Event) {
|
func (portal *Portal) HandleMatrixReaction(sender *User, evt *event.Event) {
|
||||||
|
|
Loading…
Reference in a new issue