Skip to content

Commit 3441992

Browse files
committed
up for mtk parent change
1 parent 0584001 commit 3441992

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/spatial_reaction_systems/lattice_reaction_systems.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ struct LatticeReactionSystem{Q, R, S, T} <: MT.AbstractTimeDependentSystem
117117
if !isempty(MT.continuous_events(rs)) || !isempty(MT.discrete_events(rs))
118118
throw(ArgumentError("The `ReactionSystem` used as input to `LatticeReactionSystem` contain events. These will be ignored in any simulations based on the created `LatticeReactionSystem`."))
119119
end
120-
if !isempty(MT.get_parent(rs))
120+
if !isnothing(MT.get_parent(rs)) && !isempty(MT.get_systems(MT.get_parent(rs)))
121121
@warn "The `ReactionSystem` used as input to `LatticeReactionSystem` was originally created as a hierarchical model. While this won't necessarily result in errors, it has not been well-tested, and is not recommended."
122122
end
123123
if !isempty(observed(rs))

0 commit comments

Comments
 (0)