made login and password easily copyable

This commit is contained in:
StNicolay 2022-10-30 16:37:24 +03:00
parent f6b58df6c4
commit ac9d89fb3d

View File

@ -13,7 +13,7 @@ Message = telebot.types.Message
def _send_tmp_message(
bot: telebot.TeleBot, chat_id: telebot.types.Message, text: str, timeout: int = 5
) -> None:
bot_mes = bot.send_message(chat_id, text)
bot_mes = bot.send_message(chat_id, text, parse_mode="MarkdownV2")
time.sleep(timeout)
bot.delete_message(chat_id, bot_mes.id)
@ -273,7 +273,7 @@ def _get_account3(
login, passwd = cryptography.other_accounts.decrypt_account_info(
enc_login, enc_pass, text.encode("utf-8"), salt
)
_send_tmp_message(bot, mes.chat.id, f"Логин:\n{login}\nПароль:\n{passwd}", 30)
_send_tmp_message(bot, mes.chat.id, f"Логин:\n`{login}`\nПароль:\n`{passwd}`", 30)
del text, mes, passwd, login
gc.collect()