File tree Expand file tree Collapse file tree 2 files changed +12
-2
lines changed
packages/react-reconciler/src Expand file tree Collapse file tree 2 files changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -580,7 +580,12 @@ export function processUpdateQueue<State>(
580
580
instance ,
581
581
) ;
582
582
const callback = update . callback ;
583
- if ( callback !== null ) {
583
+ if (
584
+ callback !== null &&
585
+ // If the update was already committed, we should not queue its
586
+ // callback again.
587
+ update . lane !== NoLane
588
+ ) {
584
589
workInProgress . flags |= Callback ;
585
590
const effects = queue . effects ;
586
591
if ( effects === null ) {
Original file line number Diff line number Diff line change @@ -580,7 +580,12 @@ export function processUpdateQueue<State>(
580
580
instance ,
581
581
) ;
582
582
const callback = update . callback ;
583
- if ( callback !== null ) {
583
+ if (
584
+ callback !== null &&
585
+ // If the update was already committed, we should not queue its
586
+ // callback again.
587
+ update . lane !== NoLane
588
+ ) {
584
589
workInProgress . flags |= Callback ;
585
590
const effects = queue . effects ;
586
591
if ( effects === null ) {
You can’t perform that action at this time.
0 commit comments