Skip to content

Commit

Permalink
fix: components can use callback
Browse files Browse the repository at this point in the history
  • Loading branch information
moversekostas committed Nov 8, 2024
1 parent ec3075b commit b3fc252
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions moai/engine/callbacks/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@ def __init__(
super().__init__(list)
if model:
self.data.extend((c for c in model.children() if isinstance(c, Callback)))
for c in model.children():
for k, v in c.items():
if isinstance(v, Callback):
self.data.append(v)

if hasattr(model, "named_monitors"):
# search within named monitors
# for callbacks
Expand Down

0 comments on commit b3fc252

Please sign in to comment.