diff --git a/main.py b/main.py index e98abc8..c0b03e6 100644 --- a/main.py +++ b/main.py @@ -266,8 +266,8 @@ class ChenBot(ClientXMPP): print(e) cm = ctx.pop(0) - if cm in self.muc_commands: - self.muc_commands[cm](msg, ctx, sender) + if cm in self.commands: + self.commands[cm](msg, ctx, sender) async def muc_message(self, msg): """Process a groupchat message.""" @@ -290,7 +290,7 @@ class ChenBot(ClientXMPP): if cm in self.muc_commands: self.muc_commands[cm](msg, ctx, sender) - @self.muc_word + @self.muc_command def repo(msg, ctx, sender): if ctx: return @@ -300,16 +300,6 @@ class ChenBot(ClientXMPP): mtype="groupchat", ) - @self.word - def repo(msg, ctx, sender): - if ctx: - return - bot.send_message( - mto=sender, - mbody=f"{msg.get_from().bare}: https://git.chaotic.ninja/usr/yakumo_izuru/chen", - mtype="chat", - ) - if __name__ == "__main__": config = configparser.ConfigParser() config.read("config.ini")