mirror of
https://github.com/aiogram/aiogram.git
synced 2026-04-08 16:37:47 +00:00
Add support for a list of ids and update the example
This commit is contained in:
parent
6a3c13ed50
commit
6bbc808a3b
2 changed files with 23 additions and 16 deletions
|
|
@ -42,5 +42,11 @@ async def handler5(msg: types.Message):
|
|||
await bot.send_message(msg.chat.id,
|
||||
"Hello from user= & chat_id=")
|
||||
|
||||
|
||||
@dp.message_handler(user=[user_id_to_test, 123]) # todo: add second id here
|
||||
async def handler6(msg: types.Message):
|
||||
print("Checked with list!")
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
executor.start_polling(dp)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue