Skip to content
Myr

fix: remove pointless assignments

Before adoption: this commit came in with the history the project adopted, so no landing records it.

The value of `state.finalizing` is guaranteed to be true at this point. And setting `finalizing` to false might be harmful.

authored by Alec Larson · committed by Alec Larson · parent ff96173 · Browse files · 1 file+0 added−2 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+0 added−2 removed

  • other:+0 added−2 removed

1 file+0 added−2 removed

modified:src/immer.js-2 removed
227 unmodified lines
228 const state = root[DRAFT_STATE]229 if (state) {230 if (!this.useProxies) {231 // Create the final copy, with added keys and without deleted keys.232 state.finalizing = true232 state.copy = shallowCopy(state.draft, true)234 state.finalizing = false233 }234 root = state.copy235 }236
51 unmodified lines