@bot.event
async def on_message(message,ctx):
rolemute = discord.utils.get(ctx.guild.roles, name=('Muted'))
if rolemute in ctx.author.roles:
await ctx.channel.purge(limit=1)
await bot.process_commands(message)
https://discordpy.readthedocs.io/en/latest/api.htm...
@bot.event
async def on_message(message):
rolemute = discord.utils.get(message.guild.roles, name=('Muted'))
if rolemute in message.author.roles:
await message.channel.purge(limit=1)
await bot.process_commands(message)