mirror of
https://github.com/aiogram/aiogram.git
synced 2025-12-17 12:34:39 +00:00
misc: code consistency and bot instance creation (#1482)
* misc: code consistency and bot instance creation * Changelog for aiogram#1482 * misc: consistency of comments and dispatcher instance creation * misc: removed routers example * Update CHANGES/1482.misc.rst --------- Co-authored-by: Alex Root Junior <jroot.junior@gmail.com>
This commit is contained in:
parent
b08ba78898
commit
e3dc7d576b
13 changed files with 54 additions and 30 deletions
|
|
@ -1,5 +1,5 @@
|
|||
from aiogram import Bot, F, Router
|
||||
from aiogram.filters import Command
|
||||
from aiogram.filters import Command, CommandStart
|
||||
from aiogram.types import (
|
||||
InlineKeyboardButton,
|
||||
InlineKeyboardMarkup,
|
||||
|
|
@ -11,7 +11,7 @@ from aiogram.types import (
|
|||
my_router = Router()
|
||||
|
||||
|
||||
@my_router.message(Command("start"))
|
||||
@my_router.message(CommandStart())
|
||||
async def command_start(message: Message, bot: Bot, base_url: str):
|
||||
await bot.set_chat_menu_button(
|
||||
chat_id=message.chat.id,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue