From 04e7d9f1a2f0c3a643e54e8dab23b96ca81f4867 Mon Sep 17 00:00:00 2001 From: christian Date: Thu, 12 Aug 2021 18:25:16 +0200 Subject: [PATCH] added ignore list --- suggestionsbot/discord_suggestions.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/suggestionsbot/discord_suggestions.py b/suggestionsbot/discord_suggestions.py index fe37c09b..b6675871 100644 --- a/suggestionsbot/discord_suggestions.py +++ b/suggestionsbot/discord_suggestions.py @@ -5,6 +5,7 @@ from settings import token import datetime client = discord.Client() +ignore_list = [] #shit api. got switched like 1 year ago so like every single discusison about it is outdated. def get_suggestion_type(msg): @@ -33,6 +34,10 @@ def get_suggestion_type(msg): async def on_message(message): if message.author.bot: return + if message.author.id in ignore_list: + msg = f'{message.author.name} Your suggestion was ignored because you made too many shitty suggestions already. Do not post in this channel anymore.' + await message.channel.send() + return if message.channel.name == 'suggestion-box': #suggestion-box channel = client.get_channel(872925751295504476) #872925751295504476 message_content = message.content