From 39cf6546032526c408b5dad7701a2315293423f9 Mon Sep 17 00:00:00 2001 From: Jared Vititoe Date: Sun, 1 Feb 2026 11:50:34 -0500 Subject: [PATCH] Updated the bot so wynter stops spamming when starting messages with a period. --- bot.py | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/bot.py b/bot.py index 4333c29..6ef2f79 100644 --- a/bot.py +++ b/bot.py @@ -162,7 +162,10 @@ def has_role_check(role_id: int): async def on_message(message): try: logger.info(f"Channel: [{str(message.channel)}] User: {str(message.author)} Content: {message.content}") - await client.process_commands(message) + + # Special response for user 331862422996647938 when message starts with a period + if message.author.id == 331862422996647938 and message.content.startswith('.'): + await message.channel.send("Whatever conversation is happening right now, Jared is right") except Exception as e: logger.error(f"Error in on_message: {e}", exc_info=True) @@ -1078,18 +1081,6 @@ async def userinfo(interaction: discord.Interaction, member: discord.Member): logger.error(f"Error in userinfo command: {e}", exc_info=True) -@client.event -async def on_command_error(ctx, error): - """Handle prefix command errors.""" - try: - if isinstance(error, commands.CommandNotFound): - await ctx.send("Command not found!") - logger.error(f"Command error: {str(error)}") - elif isinstance(error, commands.MissingPermissions): - await ctx.send("You don't have permission to use this command!") - logger.error(f"Command error: {str(error)}") - except Exception as e: - logger.error(f"Error in on_command_error: {e}", exc_info=True) @client.tree.error