From 1da65e662e29648fb736880d6e8b3f0e7c9a5105 Mon Sep 17 00:00:00 2001 From: Lendemor Date: Thu, 12 Dec 2024 13:55:33 +0100 Subject: [PATCH] fix typing --- reflex/components/component.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/reflex/components/component.py b/reflex/components/component.py index 311240dc8c..0a4851fc8b 100644 --- a/reflex/components/component.py +++ b/reflex/components/component.py @@ -1526,7 +1526,7 @@ def _get_hooks_internal(self) -> dict[str, None]: **self._get_special_hooks(), } - def _get_added_hooks(self) -> dict[str, VarData]: + def _get_added_hooks(self) -> dict[str, VarData | None]: """Get the hooks added via `add_hooks` method. Returns: @@ -1552,7 +1552,7 @@ def extract_var_hooks(hook: Var): if isinstance(hook, Var): extract_var_hooks(hook) else: - code[hook] = VarData() + code[hook] = None return code