From 60a23665cbac9f1851ebb6e3ed958fab47df811b Mon Sep 17 00:00:00 2001 From: _run Date: Mon, 7 Mar 2022 17:23:55 +0500 Subject: [PATCH] Update flooding_middleware.py --- .../asynchronous_telebot/middleware/flooding_middleware.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/examples/asynchronous_telebot/middleware/flooding_middleware.py b/examples/asynchronous_telebot/middleware/flooding_middleware.py index b8f589e..cc9d9f8 100644 --- a/examples/asynchronous_telebot/middleware/flooding_middleware.py +++ b/examples/asynchronous_telebot/middleware/flooding_middleware.py @@ -1,8 +1,7 @@ # Just a little example of middleware handlers -from telebot.asyncio_handler_backends import BaseMiddleware +from telebot.asyncio_handler_backends import BaseMiddleware, CancelUpdate from telebot.async_telebot import AsyncTeleBot -from telebot.async_telebot import CancelUpdate bot = AsyncTeleBot('TOKEN') @@ -36,4 +35,4 @@ async def start(message): await bot.send_message(message.chat.id, 'Hello!') import asyncio -asyncio.run(bot.polling()) \ No newline at end of file +asyncio.run(bot.polling())