Skip to content

Commit 6725400

Browse files
Hypnosphitimdorr
authored andcommitted
Remove unused latestStoreState field (#1426)
* Remove unused `latestStoreState` field 1. This field doesn't actually affect anything: `action.payload` is always a fresh object anyway 2. Having reference to some arbitrary state from the past (namely, the one that triggered the last update for given component) leads to huge memory leaks if the state object is large and there are lots of connected components. * Revert redundant change
1 parent 388d9e4 commit 6725400

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

src/components/connectAdvanced.js

-1
Original file line numberDiff line numberDiff line change
@@ -350,7 +350,6 @@ export default function connectAdvanced(
350350
forceComponentUpdateDispatch({
351351
type: 'STORE_UPDATED',
352352
payload: {
353-
latestStoreState,
354353
error
355354
}
356355
})

0 commit comments

Comments
 (0)