Skip to content

Commit

Permalink
Use SendMessageEvent to ensure reactions get double puppet identifiers
Browse files Browse the repository at this point in the history
  • Loading branch information
tulir committed Aug 21, 2023
1 parent 87489f1 commit 1a14311
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion portal.go
Original file line number Diff line number Diff line change
Expand Up @@ -692,7 +692,13 @@ func (portal *Portal) syncReactions(ctx context.Context, source *User, message *
continue
}
var resp *mautrix.RespSendEvent
resp, err = intent.SendReaction(portal.MXID, message.MXID, variationselector.Add(emoji))
resp, err = intent.SendMessageEvent(portal.MXID, event.EventReaction, &event.ReactionEventContent{
RelatesTo: event.RelatesTo{
EventID: message.MXID,
Type: event.RelAnnotation,
Key: variationselector.Add(emoji),
},
})
if err != nil {
log.Err(err).Str("reaction_sender_id", participant).Msg("Failed to send reaction")
continue
Expand Down

0 comments on commit 1a14311

Please sign in to comment.