diff --git a/kaikout/xmpp/client.py b/kaikout/xmpp/client.py index e64fb7c..be9f93f 100644 --- a/kaikout/xmpp/client.py +++ b/kaikout/xmpp/client.py @@ -148,6 +148,9 @@ class XmppClient(slixmpp.ClientXMPP): .format(self.alias, self.boundjid.bare)) XmppMessage.send(self, room, message_body, 'groupchat') XmppStatus.send_status_message(self, room) + self.add_event_handler("muc::%s::got_online" % room, self.on_muc_got_online) + self.add_event_handler("muc::%s::presence" % room, self.on_muc_presence) + self.add_event_handler("muc::%s::self-presence" % room, self.on_muc_self_presence) async def on_groupchat_direct_invite(self, message): @@ -164,6 +167,9 @@ class XmppClient(slixmpp.ClientXMPP): .format(self.boundjid.bare)) XmppMessage.send(self, room, message_body, 'groupchat') XmppStatus.send_status_message(self, room) + self.add_event_handler("muc::%s::got_online" % room, self.on_muc_got_online) + self.add_event_handler("muc::%s::presence" % room, self.on_muc_presence) + self.add_event_handler("muc::%s::self-presence" % room, self.on_muc_self_presence) async def on_message(self, message):