diff --git a/code/code.py b/code/code.py index a376f49..ca627ca 100644 --- a/code/code.py +++ b/code/code.py @@ -139,6 +139,8 @@ async def on_message(message): #check if the bot hasn't been used more than 200 times in the last 24 hours (uses_count_today) c.execute("SELECT uses_count_today FROM data WHERE guild_id = ?", (message.guild.id,)) if c.fetchone()[0] >= 200: + debug("The bot has been used more than 200 times in the last 24 hours in this guild") + await message.channel.send("The bot has been used more than 200 times in the last 24 hours in this guild. Please try again in 24h.") return #add 1 to the uses_count_today c.execute("UPDATE data SET uses_count_today = uses_count_today + 1 WHERE guild_id = ?", (message.guild.id,))