chore(makeprompt.py): add print statement for debugging purposes

This commit is contained in:
Paillat
2023-05-05 14:02:47 +02:00
parent 65ed0e6e07
commit 41c73d2ee2

View File

@@ -100,13 +100,14 @@ async def need_ignore_message(bot, data_dict, message, guild_data, original_mess
if ( if (
# if the message is not in a premium channel and # if the message is not in a premium channel and
not (str(message.channel.id) in channels not (str(message.channel.id) in [str(channel) for channel in channels]
# if the message doesn't mention the bot and # if the message doesn't mention the bot and
and (message.content.find("<@" + str(bot.user.id) + ">") != -1 and (message.content.find("<@" + str(bot.user.id) + ">") != -1
or original_message)) # if the message is not a reply to the bot and or original_message)) # if the message is not a reply to the bot and
# if the message is not in the default channel # if the message is not in the default channel
and str(message.channel.id) != str(data_dict["channel_id"]) and str(message.channel.id) != str(data_dict["channel_id"])
): ):
print("Message ignored in guild " + str(message.guild.id))
return True return True
# if the bot has been used more than max_uses*5 times in the last 24 hours in this guild and the guild is premium # if the bot has been used more than max_uses*5 times in the last 24 hours in this guild and the guild is premium