From 5db622c7d4095f704b44183c9132ee405463f70f Mon Sep 17 00:00:00 2001 From: Seonghwan Choi <44457374+csh3695@users.noreply.github.com> Date: Thu, 20 Apr 2023 03:45:23 +0900 Subject: [PATCH] Apply convert_handlers_to_fns for substates (#846) --- pynecone/state.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pynecone/state.py b/pynecone/state.py index 7e1fc292c..03df6e194 100644 --- a/pynecone/state.py +++ b/pynecone/state.py @@ -194,6 +194,8 @@ class State(Base, ABC): """ for name, event_handler in cls.event_handlers.items(): setattr(cls, name, event_handler.fn) + for substate in cls.get_substates(): + substate.convert_handlers_to_fns() @classmethod def set_handlers(cls):