Skip to content

Commit 3b31b17

Browse files
fix: unwrap in vars
1 parent ae8ebe7 commit 3b31b17

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/utils.jl

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -349,7 +349,9 @@ function vars(exprs::Symbolic; op = Differential)
349349
end
350350
vars(exprs::Num; op = Differential) = vars(unwrap(exprs); op)
351351
vars(exprs::Symbolics.Arr; op = Differential) = vars(unwrap(exprs); op)
352-
vars(exprs; op = Differential) = foldl((x, y) -> vars!(x, y; op = op), exprs; init = Set())
352+
function vars(exprs; op = Differential)
353+
foldl((x, y) -> vars!(x, unwrap(y); op = op), exprs; init = Set())
354+
end
353355
vars(eq::Equation; op = Differential) = vars!(Set(), eq; op = op)
354356
function vars!(vars, eq::Equation; op = Differential)
355357
(vars!(vars, eq.lhs; op = op); vars!(vars, eq.rhs; op = op); vars)

0 commit comments

Comments
 (0)