diff --git a/app/config.py b/app/config.py index 6cdfb42..f86d7ed 100644 --- a/app/config.py +++ b/app/config.py @@ -80,7 +80,7 @@ FAQ = types.InlineKeyboardButton( LIB = types.InlineKeyboardButton("📚 Книги", url="https://telegra.ph/what-to-read-10-06") SPAM = ["me.sv/", "tg.sv/", "goo.by/", "go.sv/", "intim.video/", "uclck.ru/", 'раб0т', - '0плат', 'Жду в ЛС!', 'новый способ заработка', 'криптовалют', 'цифровых валют', 'кpuптa'] + '0плат', 'Жду в ЛС!', 'новый способ заработка', 'криптовалют', 'цифровых валют', 'кpuпт', ] NON_GRATA = ["дудар", "хауди", "dudar"] BAN_WORDS = ["GREEN"] diff --git a/app/filters.py b/app/filters.py index 44628c4..f2612e1 100644 --- a/app/filters.py +++ b/app/filters.py @@ -8,11 +8,8 @@ from .config import * def in_spam_list(message: types.Message) -> bool: """Check for mentioning unwanted persons in text.""" antispam_is_enabled = session.query(Chat.antispam).filter_by(chat_id=message.chat.id).first()[0] - logging.critical(str(antispam_is_enabled)) if message.from_user.id not in WHITEIDS and antispam_is_enabled: - logging.critical('if message.from_user.id not in WHITEIDS and antispam_is_enabled: TRUE') for text in SPAM: - logging.critical(str(text.casefold()) + ' in ' + str(message.text.casefold())) if text.casefold() in message.text.casefold(): logging.info( "!BAN!" + LOG_COMM % (