diff --git a/kabot/kabot/kabot.py b/kabot/kabot/kabot.py index 3484194..f1e162c 100644 --- a/kabot/kabot/kabot.py +++ b/kabot/kabot/kabot.py @@ -360,15 +360,16 @@ class Mybot(commands.Cog): async def say(self, ctx, *message): sentence = ' '.join(message) channel = [x for x in self.bot.get_all_channels() if x.name == "général"][0] + guild = self.bot.guilds[0] if sentence.startswith('!'): command_name = sentence.split()[0].replace('!', '') cmd = self.bot.get_command(command_name) ctx.channel = channel + ctx.guild = guild await cmd.invoke(ctx) else: for word in sentence.split(): if word.startswith('@'): - guild = self.bot.guilds[0] members = guild.members for member in members: if member.name == word[1:]: