Skip to content

Commit 82d8129

Browse files
authored
Reconciler: Change commitUpdate signature to account for unused updatePayload parameter (#28909)
1 parent d285b3a commit 82d8129

File tree

6 files changed

+2
-29
lines changed

6 files changed

+2
-29
lines changed

packages/react-art/src/ReactFiberConfigART.js

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -415,13 +415,7 @@ export function commitMount(instance, type, newProps) {
415415
// Noop
416416
}
417417

418-
export function commitUpdate(
419-
instance,
420-
updatePayload,
421-
type,
422-
oldProps,
423-
newProps,
424-
) {
418+
export function commitUpdate(instance, type, oldProps, newProps) {
425419
instance._applyProps(instance, newProps, oldProps);
426420
}
427421

packages/react-dom-bindings/src/client/ReactFiberConfigDOM.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -702,7 +702,6 @@ export function commitMount(
702702

703703
export function commitUpdate(
704704
domElement: Instance,
705-
updatePayload: any,
706705
type: string,
707706
oldProps: Props,
708707
newProps: Props,

packages/react-native-renderer/src/ReactFiberConfigNative.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -348,7 +348,6 @@ export function commitMount(
348348

349349
export function commitUpdate(
350350
instance: Instance,
351-
updatePayloadTODO: Object,
352351
type: string,
353352
oldProps: Props,
354353
newProps: Props,

packages/react-noop-renderer/src/createReactNoop.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -651,7 +651,6 @@ function createReactNoop(reconciler: Function, useMutation: boolean) {
651651

652652
commitUpdate(
653653
instance: Instance,
654-
updatePayload: Object,
655654
type: string,
656655
oldProps: Props,
657656
newProps: Props,

packages/react-reconciler/src/ReactFiberCommitWork.js

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ import type {
1313
SuspenseInstance,
1414
Container,
1515
ChildSet,
16-
UpdatePayload,
1716
HoistableRoot,
1817
FormInstance,
1918
} from './ReactFiberConfig';
@@ -2676,14 +2675,9 @@ function commitMutationEffectsOnFiber(
26762675
);
26772676
}
26782677
} else if (newResource === null && finishedWork.stateNode !== null) {
2679-
// We may have an update on a Hoistable element
2680-
const updatePayload: null | UpdatePayload =
2681-
(finishedWork.updateQueue: any);
2682-
finishedWork.updateQueue = null;
26832678
try {
26842679
commitUpdate(
26852680
finishedWork.stateNode,
2686-
updatePayload,
26872681
finishedWork.type,
26882682
current.memoizedProps,
26892683
finishedWork.memoizedProps,
@@ -2754,19 +2748,8 @@ function commitMutationEffectsOnFiber(
27542748
const oldProps =
27552749
current !== null ? current.memoizedProps : newProps;
27562750
const type = finishedWork.type;
2757-
// TODO: Type the updateQueue to be specific to host components.
2758-
const updatePayload: null | UpdatePayload =
2759-
(finishedWork.updateQueue: any);
2760-
finishedWork.updateQueue = null;
27612751
try {
2762-
commitUpdate(
2763-
instance,
2764-
updatePayload,
2765-
type,
2766-
oldProps,
2767-
newProps,
2768-
finishedWork,
2769-
);
2752+
commitUpdate(instance, type, oldProps, newProps, finishedWork);
27702753
} catch (error) {
27712754
captureCommitPhaseError(finishedWork, finishedWork.return, error);
27722755
}

packages/react-test-renderer/src/ReactFiberConfigTestHost.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,6 @@ export const supportsMutation = true;
237237

238238
export function commitUpdate(
239239
instance: Instance,
240-
updatePayload: null | {...},
241240
type: string,
242241
oldProps: Props,
243242
newProps: Props,

0 commit comments

Comments
 (0)