mirror of
https://github.com/aiogram/aiogram.git
synced 2025-12-11 18:01:04 +00:00
Fixed lines in FSM example
This commit is contained in:
parent
dc7c99763e
commit
a332e88bc3
2 changed files with 13 additions and 34 deletions
|
|
@ -24,7 +24,7 @@ class Form(StatesGroup):
|
|||
language = State()
|
||||
|
||||
|
||||
@form_router.message(Command(commands=["start"]))
|
||||
@form_router.message(Command("start"))
|
||||
async def command_start(message: Message, state: FSMContext) -> None:
|
||||
await state.set_state(Form.name)
|
||||
await message.answer(
|
||||
|
|
@ -33,7 +33,7 @@ async def command_start(message: Message, state: FSMContext) -> None:
|
|||
)
|
||||
|
||||
|
||||
@form_router.message(Command(commands=["cancel"]))
|
||||
@form_router.message(Command("cancel"))
|
||||
@form_router.message(F.text.casefold() == "cancel")
|
||||
async def cancel_handler(message: Message, state: FSMContext) -> None:
|
||||
"""
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue