mirror of
https://github.com/maubot/maubot.git
synced 2024-10-01 01:06:10 -04:00
Don't re-wrap events if they're re-dispatched
This commit is contained in:
parent
ebd4ae9f55
commit
0a47d1929a
@ -126,7 +126,7 @@ class MaubotMatrixClient(MatrixClient):
|
||||
return self.send_message(room_id, content, **kwargs)
|
||||
|
||||
def dispatch_event(self, event: Event, source: SyncStream) -> List[asyncio.Task]:
|
||||
if isinstance(event, MessageEvent):
|
||||
if isinstance(event, MessageEvent) and not isinstance(event, MaubotMessageEvent):
|
||||
event = MaubotMessageEvent(event, self)
|
||||
elif source != SyncStream.INTERNAL:
|
||||
event.client = self
|
||||
|
Loading…
Reference in New Issue
Block a user