connector/matrix: send UNSUPPORTED MSS for invalid reactions
Signed-off-by: Sumner Evans <sumner.evans@automattic.com>
This commit is contained in:
@@ -428,6 +428,12 @@ func (t *TelegramClient) HandleMatrixReaction(ctx context.Context, msg *bridgev2
|
|||||||
MsgID: targetMessageID,
|
MsgID: targetMessageID,
|
||||||
Reaction: newReactions,
|
Reaction: newReactions,
|
||||||
})
|
})
|
||||||
|
if tg.IsReactionInvalid(err) {
|
||||||
|
return nil, bridgev2.WrapErrorInStatus(err).
|
||||||
|
WithErrorReason(event.MessageStatusUnsupported).
|
||||||
|
WithIsCertain(true).
|
||||||
|
WithMessage("Unsupported reaction")
|
||||||
|
}
|
||||||
return &database.Reaction{}, err
|
return &database.Reaction{}, err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user