How do I make my bot delete a message when it contains a certain word?
问题 Okay so I'm trying to make a filter for my bot, but one that isn't too complicated. I've got this: @bot.event async def on_message(ctx,message): if 'fuck' in Message.content.lower: Message.delete() But it gives the error: Ignoring exception in on_message Traceback (most recent call last): File "C:\Users\user\AppData\Local\Programs\Python\Python38-32\lib\site-packages\discord\client.py", line 270, in _run_event await coro(*args, **kwargs) TypeError: on_message() missing 1 required positional