Skip to content

Commit bbf6d5a

Browse files
committed
fix use_debug hook
1 parent 9a9fd95 commit bbf6d5a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/idom/core/hooks.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323

2424
from typing_extensions import Protocol
2525

26+
from idom.config import IDOM_DEBUG_MODE
2627
from idom.utils import Ref
2728

2829
from ._thread_local import ThreadLocal
@@ -212,7 +213,7 @@ def use_debug_value(
212213
memo_func = message if callable(message) else lambda: message
213214
new = use_memo(memo_func, dependencies)
214215

215-
if old.current != new:
216+
if IDOM_DEBUG_MODE.current and old.current != new:
216217
old.current = new
217218
logger.debug(f"{current_hook().component} {new}")
218219

0 commit comments

Comments
 (0)