Looking in a Discord message for bad words?
I am currently trying to make my own Discord bot (I'm not very good) and I want to filter the messages the bot gets for bad words. So what I researched and tried was this:
Here I made another Python script for the words because I wanted to keep the code organized. The other script is a simple list.
from badwords import *
if badwords.badword in message:
await message.channel.send('Thats not nice! STOP!')
I also tried the any() method but I removed that and now I don't have that anymore and it didn't work too.
from Recent Questions - Stack Overflow https://ift.tt/3d9bQUS
https://ift.tt/eA8V8J
Comments
Post a Comment