Skip to content

Commit 5fe1e30

Browse files
fixup! fix: handle => nothing entries in u0map in generate_initializesystem
1 parent 0419607 commit 5fe1e30

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/systems/nonlinear/initializesystem.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ function generate_initializesystem(sys::AbstractSystem;
3232

3333
# PREPROCESSING
3434
# If `=> nothing` in `u0map`, remove the key from `defs`
35+
u0map = copy(anydict(u0map))
3536
for (k, v) in u0map
3637
v === nothing || continue
3738
delete!(defs, k)
@@ -44,7 +45,6 @@ function generate_initializesystem(sys::AbstractSystem;
4445
# map parameters in `initprob` which need to be updated in `update_initializeprob!`
4546
# to the corresponding expressions that determine their values
4647
new_params = Dict()
47-
u0map = copy(anydict(u0map))
4848
pmap = copy(anydict(pmap))
4949
if is_time_dependent(sys)
5050
for (k, v) in u0map

0 commit comments

Comments
 (0)