From 72b7e81f9700dd1da9ec0ae41e440ace9831fab3 Mon Sep 17 00:00:00 2001 From: Tulir Asokan Date: Fri, 21 Jun 2019 14:40:12 +0300 Subject: [PATCH] Change event.react() to use client.react() --- maubot/matrix.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/maubot/matrix.py b/maubot/matrix.py index 99d67f9..f68bd12 100644 --- a/maubot/matrix.py +++ b/maubot/matrix.py @@ -72,9 +72,7 @@ class MaubotMessageEvent(MessageEvent): return self.client.send_receipt(self.room_id, self.event_id, "m.read") def react(self, key: str) -> Awaitable[None]: - content = ReactionEventContent(relates_to=RelatesTo(rel_type=RelationType.ANNOTATION, - event_id=self.event_id, key=key)) - return self.client.send_message_event(self.room_id, EventType.REACTION, content) + return self.client.react(self.room_id, self.event_id, key) class MaubotMatrixClient(MatrixClient):