From 74844da4aeb4d4cdc214ac6fe7a20eb416e337ac Mon Sep 17 00:00:00 2001 From: StNicolay Date: Fri, 30 Dec 2022 13:54:03 +0300 Subject: [PATCH] Added backslash to the forbidden chars --- src/account_checks.py | 2 +- src/bot/message_handlers.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/account_checks.py b/src/account_checks.py index 2023516..be40ecb 100644 --- a/src/account_checks.py +++ b/src/account_checks.py @@ -2,7 +2,7 @@ import string from .decrypted_account import DecryptedAccount -FORBIDDEN_CHARS = frozenset("`\n") +FORBIDDEN_CHARS = frozenset("`\n\\") PUNCTUATION = frozenset(string.punctuation).difference(FORBIDDEN_CHARS) diff --git a/src/bot/message_handlers.py b/src/bot/message_handlers.py index 8037a93..6baa371 100644 --- a/src/bot/message_handlers.py +++ b/src/bot/message_handlers.py @@ -658,7 +658,7 @@ async def _import3( async def gen_password(bot: AsyncTeleBot, mes: Message) -> None: await base_handler(bot, mes) - # Generate 10 passwords and put 'em in the backticks + # Generate 10 passwords and put them in the backticks passwords = (f"`{generate_password.gen_password()}`" for _ in range(10)) text = ( "Пароли:\n"