Fixed the order of handlers in the Scene

This commit is contained in:
RootShinobi 2024-11-27 20:36:49 +02:00
parent e79ab53dce
commit 98af2256d1

View file

@ -323,7 +323,7 @@ class Scene:
if callback_query_without_state is None:
callback_query_without_state = parent_scene_config.callback_query_without_state
for name in vars(cls):
for name in dir(cls):
value = getattr(cls, name)
if scene_handlers := getattr(value, "__aiogram_handler__", None):
handlers.extend(scene_handlers)