Fix encrypting outgoing Matrix events after restart

This commit is contained in:
Tulir Asokan
2020-03-30 01:04:12 +03:00
parent 50ec2551f8
commit 37917c497e
2 changed files with 7 additions and 1 deletions
+6
View File
@@ -48,8 +48,14 @@ class MatrixHandler(BaseMatrixHandler):
previously_typing: Dict[RoomID, Set[UserID]]
def __init__(self, context: 'Context') -> None:
prefix, suffix = context.config["bridge.username_template"].format(userid=":").split(":")
homeserver = context.config["homeserver.domain"]
self.user_id_prefix = f"@{prefix}"
self.user_id_suffix = f"{suffix}:{homeserver}"
super(MatrixHandler, self).__init__(context.az, context.config, loop=context.loop,
command_processor=com.CommandProcessor(context))
self.bot = context.bot
self.previously_typing = {}