fix: avoid unnecessary read version increments (#15777)

Fixes #15262
pull/15779/head
Simon H 5 months ago committed by GitHub
parent e079ac92b8
commit ea4843c5ad
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -0,0 +1,5 @@
---
'svelte': patch
---
fix: avoid unnecessary read version increments

@ -469,7 +469,7 @@ export function update_reaction(reaction) {
// we need to increment the read version to ensure that
// any dependencies in this reaction aren't marked with
// the same version
if (previous_reaction !== reaction) {
if (previous_reaction !== null && previous_reaction !== reaction) {
read_version++;
if (untracked_writes !== null) {

Loading…
Cancel
Save