Skip to content

Commit bc6a186

Browse files
fix: unwrap in vars
1 parent 4d7f974 commit bc6a186

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
@@ -370,7 +370,9 @@ function vars(exprs::Symbolic; op = Differential)
370370
end
371371
vars(exprs::Num; op = Differential) = vars(unwrap(exprs); op)
372372
vars(exprs::Symbolics.Arr; op = Differential) = vars(unwrap(exprs); op)
373-
vars(exprs; op = Differential) = foldl((x, y) -> vars!(x, y; op = op), exprs; init = Set())
373+
function vars(exprs; op = Differential)
374+
foldl((x, y) -> vars!(x, unwrap(y); op = op), exprs; init = Set())
375+
end
374376
vars(eq::Equation; op = Differential) = vars!(Set(), eq; op = op)
375377
function vars!(vars, eq::Equation; op = Differential)
376378
(vars!(vars, eq.lhs; op = op); vars!(vars, eq.rhs; op = op); vars)

0 commit comments

Comments
 (0)