From 533b3b5b03de5667b65477b8908b9a0597cfbdda Mon Sep 17 00:00:00 2001 From: hhaensel Date: Thu, 12 Dec 2024 23:22:25 +0100 Subject: [PATCH] fix context in init_model --- src/ReactiveTools.jl | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/ReactiveTools.jl b/src/ReactiveTools.jl index 86b6cd6..93fb988 100644 --- a/src/ReactiveTools.jl +++ b/src/ReactiveTools.jl @@ -531,9 +531,8 @@ function init_model(M::Type{<:ReactiveModel}, args...; context = nothing, kwargs end end - - handlersfn = if context !== nothing && isdefined(M, :__GF_AUTO_HANDLERS__) - M.__GF_AUTO_HANDLERS__ + handlersfn = if context !== nothing && isdefined(m, :__GF_AUTO_HANDLERS__) + m.__GF_AUTO_HANDLERS__ else Stipple.ReactiveTools.HANDLERS_FUNCTIONS[M] end