From 31c151d4a0ed5a3b5c5f42551f26621e32da055e Mon Sep 17 00:00:00 2001 From: Alex Root Junior Date: Sat, 8 Jul 2023 03:19:07 +0300 Subject: [PATCH] Fixe docstring of the bind method --- aiogram/client/context_controller.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/aiogram/client/context_controller.py b/aiogram/client/context_controller.py index 351a7caf..d2402018 100644 --- a/aiogram/client/context_controller.py +++ b/aiogram/client/context_controller.py @@ -16,7 +16,12 @@ class BotContextController(BaseModel): else: self._bot = __context.get("bot") - def as_(self, bot: "Bot") -> Self: - """Bind object to a bot instance.""" + def as_(self, bot: Optional["Bot"]) -> Self: + """ + Bind object to a bot instance. + + :param bot: Bot instance + :return: self + """ self._bot = bot return self