Fix HTML parse_mode in registration handlers to support premium emojis
Some checks failed
continuous-integration/drone/pr Build is failing
Some checks failed
continuous-integration/drone/pr Build is failing
- Replace Markdown double asterisks with HTML tags - Change parse_mode from Markdown to HTML for registration confirmation - Use <b> tags for bold text in registration_completed message - Use <code> tags for verification code display - Fixes 'Can't find end of the entity' error in Telegram API - Remove unused JSON export files
This commit is contained in:
@@ -184,12 +184,12 @@ async def process_phone(message: Message, state: FSMContext):
|
||||
"✅ Регистрация завершена!\n\n"
|
||||
f"🎭 Никнейм: {user.nickname}\n"
|
||||
f"🎫 Клубная карта: {user.club_card_number}\n"
|
||||
f"🔑 Ваш код верификации: **{user.verification_code}**\n\n"
|
||||
f"🔑 Ваш код верификации: <b>{user.verification_code}</b>\n\n"
|
||||
"⚠️ Сохраните этот код! Он понадобится для подтверждения выигрыша.\n\n"
|
||||
"Теперь вы можете участвовать в розыгрышах!"
|
||||
)
|
||||
|
||||
await message.answer(text, parse_mode="Markdown")
|
||||
await message.answer(text, parse_mode="HTML")
|
||||
await state.clear()
|
||||
|
||||
except ValueError as e:
|
||||
@@ -215,12 +215,12 @@ async def show_verification_code(message: Message):
|
||||
|
||||
text = (
|
||||
"🔑 Ваш код верификации:\n\n"
|
||||
f"**{user.verification_code}**\n\n"
|
||||
f"<code>{user.verification_code}</code>\n\n"
|
||||
"Этот код используется для подтверждения выигрыша.\n"
|
||||
"Сообщите его администратору при получении приза."
|
||||
)
|
||||
|
||||
await message.answer(text, parse_mode="Markdown")
|
||||
await message.answer(text, parse_mode="HTML")
|
||||
|
||||
|
||||
@router.message(Command("my_accounts"))
|
||||
|
||||
Reference in New Issue
Block a user