Skip to content

Commit d169565

Browse files
Remove non-split-related changes (OnyxDerived, tests)
Reverts changes to OnyxDerived/index.ts, OnyxDerived/types.ts, CardFeedErrorsDerivedValueTest.ts, and OnyxDerivedTest.tsx to keep only the split distance currency fix. Co-authored-by: Yauheni Horbach <ZhenjaHorbach@users.noreply.github.com>
1 parent 01d9cd3 commit d169565

4 files changed

Lines changed: 1 addition & 6 deletions

File tree

src/libs/actions/OnyxDerived/index.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ function init() {
5656
const context: DerivedValueContext<typeof key, typeof dependencies> = {
5757
currentValue: undefined,
5858
sourceValues: undefined,
59-
areAllConnectionsSet: false,
6059
};
6160

6261
const recomputeDerivedValue = (sourceKey?: string, sourceValue?: unknown, triggeredByIndex?: number) => {
@@ -75,7 +74,6 @@ function init() {
7574
}
7675

7776
context.currentValue = derivedValue;
78-
context.areAllConnectionsSet = areAllConnectionsSet;
7977
context.sourceValues = sourceKey && sourceValue !== undefined ? {[sourceKey]: sourceValue} : undefined;
8078

8179
// @ts-expect-error TypeScript can't confirm the shape of dependencyValues matches the compute function's parameters

src/libs/actions/OnyxDerived/types.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ type DerivedSourceValues<Deps extends readonly OnyxKey[]> = Partial<{
1616
type DerivedValueContext<Key extends OnyxKey, Deps extends NonEmptyTuple<Exclude<OnyxKey, Key>>> = {
1717
currentValue?: OnyxValue<Key>;
1818
sourceValues?: DerivedSourceValues<Deps>;
19-
areAllConnectionsSet: boolean;
2019
};
2120

2221
/**

tests/unit/CardFeedErrorsDerivedValueTest.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ import type {CardFeedWithDomainID, CardFeedWithNumber} from '@src/types/onyx/Car
1010
const DERIVED_VALUE_CONTEXT: DerivedValueContext<typeof cardFeedErrorsConfig.key, typeof cardFeedErrorsConfig.dependencies> = {
1111
currentValue: undefined,
1212
sourceValues: undefined,
13-
areAllConnectionsSet: false,
1413
};
1514

1615
const CARD_FEEDS = {

tests/unit/OnyxDerivedTest.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -123,9 +123,8 @@ describe('OnyxDerived', () => {
123123
const transaction = createRandomTransaction(1);
124124

125125
// When the report attributes are recomputed with both report and transaction updates
126-
reportAttributes.compute([reports, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined], {areAllConnectionsSet: false});
126+
reportAttributes.compute([reports, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined], {});
127127
const reportAttributesComputedValue = reportAttributes.compute([reports, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined], {
128-
areAllConnectionsSet: false,
129128
sourceValues: {
130129
[ONYXKEYS.COLLECTION.REPORT]: {
131130
[`${ONYXKEYS.COLLECTION.REPORT}${reportID1}`]: reports[`${ONYXKEYS.COLLECTION.REPORT}${reportID1}`],

0 commit comments

Comments
 (0)