@salesforce/lds-adapters-revenue-billing-batch 1.134.7 → 1.134.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (17) hide show
  1. package/dist/es/es2018/revenue-billing-batch.js +7 -39
  2. package/dist/es/es2018/types/src/generated/adapters/adapter-utils.d.ts +1 -7
  3. package/dist/es/es2018/types/src/generated/types/BatchFilterCriteriaInputRepresentation.d.ts +0 -1
  4. package/dist/es/es2018/types/src/generated/types/BatchInvoiceSchedulerInputRepresentation.d.ts +0 -1
  5. package/dist/es/es2018/types/src/generated/types/BatchInvoiceSchedulerInputWrapperRepresentation.d.ts +0 -1
  6. package/dist/es/es2018/types/src/generated/types/BillingBatchSchedulerRepresentation.d.ts +0 -1
  7. package/dist/es/es2018/types/src/generated/types/InvoicesBatchSchedulerOutputRepresentation.d.ts +0 -1
  8. package/dist/es/es2018/types/src/generated/types/PaymentRunBatchFilterCriteriaInputRepresentation.d.ts +0 -1
  9. package/dist/es/es2018/types/src/generated/types/PaymentRunBatchFilterCriteriaInputRepresentations.d.ts +0 -1
  10. package/dist/es/es2018/types/src/generated/types/PaymentsBatchSchedulerInputRepresentation.d.ts +0 -1
  11. package/dist/es/es2018/types/src/generated/types/PaymentsBatchSchedulerInputWrapperRepresentation.d.ts +0 -1
  12. package/dist/es/es2018/types/src/generated/types/PaymentsBatchSchedulerOutputRepresentation.d.ts +0 -1
  13. package/dist/es/es2018/types/src/generated/types/ScheduleOptionsInputRepresentation.d.ts +0 -1
  14. package/dist/es/es2018/types/src/generated/types/ScheduleOptionsInputRepresentationForInvoice.d.ts +0 -1
  15. package/dist/es/es2018/types/src/generated/types/type-utils.d.ts +1 -8
  16. package/package.json +1 -1
  17. package/sfdc/index.js +8 -40
@@ -4,10 +4,10 @@
4
4
  * For full license text, see the LICENSE.txt file
5
5
  */
6
6
 
7
- import { serializeStructuredKey, StoreKeyMap } from '@luvio/engine';
7
+ import { serializeStructuredKey, StoreKeyMap, deepFreeze } from '@luvio/engine';
8
8
 
9
9
  const { hasOwnProperty: ObjectPrototypeHasOwnProperty } = Object.prototype;
10
- const { keys: ObjectKeys$1, freeze: ObjectFreeze$1, create: ObjectCreate$1 } = Object;
10
+ const { keys: ObjectKeys, create: ObjectCreate } = Object;
11
11
  const { isArray: ArrayIsArray$1 } = Array;
12
12
  /**
13
13
  * Validates an adapter config is well-formed.
@@ -31,7 +31,7 @@ function validateConfig(config, adapter, oneOf) {
31
31
  throw new TypeError(`adapter ${displayName} does not yet support ${unsupported.sort().join(', ')}`);
32
32
  }
33
33
  const supported = required.concat(optional);
34
- if (ObjectKeys$1(config).some(key => !supported.includes(key))) {
34
+ if (ObjectKeys(config).some(key => !supported.includes(key))) {
35
35
  throw new TypeError(`adapter ${displayName} configuration supports only ${supported.sort().join(', ')}`);
36
36
  }
37
37
  }
@@ -43,27 +43,8 @@ function areRequiredParametersPresent(config, configPropertyNames) {
43
43
  }
44
44
  const keyPrefix = 'BillingBatch';
45
45
 
46
- const { freeze: ObjectFreeze, keys: ObjectKeys, create: ObjectCreate, assign: ObjectAssign } = Object;
47
46
  const { isArray: ArrayIsArray } = Array;
48
47
  const { stringify: JSONStringify } = JSON;
49
- function deepFreeze$3(value) {
50
- // No need to freeze primitives
51
- if (typeof value !== 'object' || value === null) {
52
- return;
53
- }
54
- if (ArrayIsArray(value)) {
55
- for (let i = 0, len = value.length; i < len; i += 1) {
56
- deepFreeze$3(value[i]);
57
- }
58
- }
59
- else {
60
- const keys = ObjectKeys(value);
61
- for (let i = 0, len = keys.length; i < len; i += 1) {
62
- deepFreeze$3(value[keys[i]]);
63
- }
64
- }
65
- ObjectFreeze(value);
66
- }
67
48
  function createLink(ref) {
68
49
  return {
69
50
  __ref: serializeStructuredKey(ref),
@@ -165,9 +146,6 @@ function validate$4(obj, path = 'BillingBatchSchedulerRepresentation') {
165
146
  })();
166
147
  return v_error === undefined ? null : v_error;
167
148
  }
168
- function deepFreeze$2(input) {
169
- ObjectFreeze(input);
170
- }
171
149
 
172
150
  const TTL$1 = 1000;
173
151
  const VERSION$1 = "eff71edc32270b9a1e6e1779cb811c3c";
@@ -214,11 +192,6 @@ function equals$1(existing, incoming) {
214
192
  }
215
193
  return true;
216
194
  }
217
- function deepFreeze$1(input) {
218
- const input_billingBatchScheduler = input.billingBatchScheduler;
219
- deepFreeze$2(input_billingBatchScheduler);
220
- ObjectFreeze(input);
221
- }
222
195
  const ingest$1 = function PaymentsBatchSchedulerOutputRepresentationIngest(input, path, luvio, store, timestamp) {
223
196
  if (process.env.NODE_ENV !== 'production') {
224
197
  const validateError = validate$3(input);
@@ -235,7 +208,6 @@ const ingest$1 = function PaymentsBatchSchedulerOutputRepresentationIngest(input
235
208
  propertyName: path.propertyName,
236
209
  ttl: ttlToUse
237
210
  });
238
- deepFreeze$1(input);
239
211
  if (existingRecord === undefined || equals$1(existingRecord, incomingRecord) === false) {
240
212
  luvio.storePublish(key, incomingRecord);
241
213
  }
@@ -282,6 +254,7 @@ function ingestSuccess$1(luvio, resourceParams, response) {
282
254
  throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
283
255
  }
284
256
  }
257
+ deepFreeze(snapshot.data);
285
258
  return snapshot;
286
259
  }
287
260
  function createResourceRequest$1(config) {
@@ -345,7 +318,7 @@ function buildNetworkSnapshot$1(luvio, config, options) {
345
318
  return luvio.storeBroadcast().then(() => snapshot);
346
319
  }, () => getResponseCacheKeys$1(luvio, resourceParams, response.body));
347
320
  }, (response) => {
348
- deepFreeze$3(response);
321
+ deepFreeze(response);
349
322
  throw response;
350
323
  });
351
324
  }
@@ -483,11 +456,6 @@ function equals(existing, incoming) {
483
456
  }
484
457
  return true;
485
458
  }
486
- function deepFreeze(input) {
487
- const input_billingBatchScheduler = input.billingBatchScheduler;
488
- deepFreeze$2(input_billingBatchScheduler);
489
- ObjectFreeze(input);
490
- }
491
459
  const ingest = function InvoicesBatchSchedulerOutputRepresentationIngest(input, path, luvio, store, timestamp) {
492
460
  if (process.env.NODE_ENV !== 'production') {
493
461
  const validateError = validate(input);
@@ -504,7 +472,6 @@ const ingest = function InvoicesBatchSchedulerOutputRepresentationIngest(input,
504
472
  propertyName: path.propertyName,
505
473
  ttl: ttlToUse
506
474
  });
507
- deepFreeze(input);
508
475
  if (existingRecord === undefined || equals(existingRecord, incomingRecord) === false) {
509
476
  luvio.storePublish(key, incomingRecord);
510
477
  }
@@ -551,6 +518,7 @@ function ingestSuccess(luvio, resourceParams, response) {
551
518
  throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
552
519
  }
553
520
  }
521
+ deepFreeze(snapshot.data);
554
522
  return snapshot;
555
523
  }
556
524
  function createResourceRequest(config) {
@@ -614,7 +582,7 @@ function buildNetworkSnapshot(luvio, config, options) {
614
582
  return luvio.storeBroadcast().then(() => snapshot);
615
583
  }, () => getResponseCacheKeys(luvio, resourceParams, response.body));
616
584
  }, (response) => {
617
- deepFreeze$3(response);
585
+ deepFreeze(response);
618
586
  throw response;
619
587
  });
620
588
  }
@@ -3,17 +3,11 @@ export declare const ObjectPrototypeHasOwnProperty: (v: PropertyKey) => boolean;
3
3
  declare const ObjectKeys: {
4
4
  (o: object): string[];
5
5
  (o: {}): string[];
6
- }, ObjectFreeze: {
7
- <T extends Function>(f: T): T;
8
- <T_1 extends {
9
- [idx: string]: object | U | null | undefined;
10
- }, U extends string | number | bigint | boolean | symbol>(o: T_1): Readonly<T_1>;
11
- <T_2>(o: T_2): Readonly<T_2>;
12
6
  }, ObjectCreate: {
13
7
  (o: object | null): any;
14
8
  (o: object | null, properties: PropertyDescriptorMap & ThisType<any>): any;
15
9
  };
16
- export { ObjectFreeze, ObjectCreate, ObjectKeys };
10
+ export { ObjectCreate, ObjectKeys };
17
11
  export declare const ArrayIsArray: (arg: any) => arg is any[];
18
12
  export declare const ArrayPrototypePush: (...items: any[]) => number;
19
13
  export interface AdapterValidationConfig {
@@ -5,7 +5,6 @@ export declare const RepresentationType: string;
5
5
  export declare function normalize(input: BatchFilterCriteriaInputRepresentation, existing: BatchFilterCriteriaInputRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): BatchFilterCriteriaInputRepresentationNormalized;
6
6
  export declare const select: () => $64$luvio_engine_FragmentSelection;
7
7
  export declare function equals(existing: BatchFilterCriteriaInputRepresentationNormalized, incoming: BatchFilterCriteriaInputRepresentationNormalized): boolean;
8
- export declare function deepFreeze(input: BatchFilterCriteriaInputRepresentation): void;
9
8
  export declare const ingest: $64$luvio_engine_ResourceIngest;
10
9
  export declare function getTypeCacheKeys(luvio: $64$luvio_engine_Luvio, input: BatchFilterCriteriaInputRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): $64$luvio_engine_DurableStoreKeyMetadataMap;
11
10
  /**
@@ -6,7 +6,6 @@ export declare const RepresentationType: string;
6
6
  export declare function normalize(input: BatchInvoiceSchedulerInputRepresentation, existing: BatchInvoiceSchedulerInputRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): BatchInvoiceSchedulerInputRepresentationNormalized;
7
7
  export declare const select: () => $64$luvio_engine_FragmentSelection;
8
8
  export declare function equals(existing: BatchInvoiceSchedulerInputRepresentationNormalized, incoming: BatchInvoiceSchedulerInputRepresentationNormalized): boolean;
9
- export declare function deepFreeze(input: BatchInvoiceSchedulerInputRepresentation): void;
10
9
  export declare const ingest: $64$luvio_engine_ResourceIngest;
11
10
  export declare function getTypeCacheKeys(luvio: $64$luvio_engine_Luvio, input: BatchInvoiceSchedulerInputRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): $64$luvio_engine_DurableStoreKeyMetadataMap;
12
11
  /**
@@ -6,7 +6,6 @@ export declare const RepresentationType: string;
6
6
  export declare function normalize(input: BatchInvoiceSchedulerInputWrapperRepresentation, existing: BatchInvoiceSchedulerInputWrapperRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): BatchInvoiceSchedulerInputWrapperRepresentationNormalized;
7
7
  export declare const select: () => $64$luvio_engine_FragmentSelection;
8
8
  export declare function equals(existing: BatchInvoiceSchedulerInputWrapperRepresentationNormalized, incoming: BatchInvoiceSchedulerInputWrapperRepresentationNormalized): boolean;
9
- export declare function deepFreeze(input: BatchInvoiceSchedulerInputWrapperRepresentation): void;
10
9
  export declare const ingest: $64$luvio_engine_ResourceIngest;
11
10
  export declare function getTypeCacheKeys(luvio: $64$luvio_engine_Luvio, input: BatchInvoiceSchedulerInputWrapperRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): $64$luvio_engine_DurableStoreKeyMetadataMap;
12
11
  /**
@@ -5,7 +5,6 @@ export declare const RepresentationType: string;
5
5
  export declare function normalize(input: BillingBatchSchedulerRepresentation, existing: BillingBatchSchedulerRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): BillingBatchSchedulerRepresentationNormalized;
6
6
  export declare const select: () => $64$luvio_engine_FragmentSelection;
7
7
  export declare function equals(existing: BillingBatchSchedulerRepresentationNormalized, incoming: BillingBatchSchedulerRepresentationNormalized): boolean;
8
- export declare function deepFreeze(input: BillingBatchSchedulerRepresentation): void;
9
8
  export declare const ingest: $64$luvio_engine_ResourceIngest;
10
9
  export declare function getTypeCacheKeys(luvio: $64$luvio_engine_Luvio, input: BillingBatchSchedulerRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): $64$luvio_engine_DurableStoreKeyMetadataMap;
11
10
  /**
@@ -16,7 +16,6 @@ export declare function keyBuilderFromType_StructuredKey(luvio: $64$luvio_engine
16
16
  export declare function normalize(input: InvoicesBatchSchedulerOutputRepresentation, existing: InvoicesBatchSchedulerOutputRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): InvoicesBatchSchedulerOutputRepresentationNormalized;
17
17
  export declare const select: () => $64$luvio_engine_BaseFragment;
18
18
  export declare function equals(existing: InvoicesBatchSchedulerOutputRepresentationNormalized, incoming: InvoicesBatchSchedulerOutputRepresentationNormalized): boolean;
19
- export declare function deepFreeze(input: InvoicesBatchSchedulerOutputRepresentation): void;
20
19
  export declare const ingest: $64$luvio_engine_ResourceIngest;
21
20
  export declare function getTypeCacheKeys(luvio: $64$luvio_engine_Luvio, input: InvoicesBatchSchedulerOutputRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): $64$luvio_engine_DurableStoreKeyMetadataMap;
22
21
  /**
@@ -6,7 +6,6 @@ export declare const RepresentationType: string;
6
6
  export declare function normalize(input: PaymentRunBatchFilterCriteriaInputRepresentation, existing: PaymentRunBatchFilterCriteriaInputRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): PaymentRunBatchFilterCriteriaInputRepresentationNormalized;
7
7
  export declare const select: () => $64$luvio_engine_FragmentSelection;
8
8
  export declare function equals(existing: PaymentRunBatchFilterCriteriaInputRepresentationNormalized, incoming: PaymentRunBatchFilterCriteriaInputRepresentationNormalized): boolean;
9
- export declare function deepFreeze(input: PaymentRunBatchFilterCriteriaInputRepresentation): void;
10
9
  export declare const ingest: $64$luvio_engine_ResourceIngest;
11
10
  export declare function getTypeCacheKeys(luvio: $64$luvio_engine_Luvio, input: PaymentRunBatchFilterCriteriaInputRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): $64$luvio_engine_DurableStoreKeyMetadataMap;
12
11
  /**
@@ -5,7 +5,6 @@ export declare const RepresentationType: string;
5
5
  export declare function normalize(input: PaymentRunBatchFilterCriteriaInputRepresentations, existing: PaymentRunBatchFilterCriteriaInputRepresentationsNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): PaymentRunBatchFilterCriteriaInputRepresentationsNormalized;
6
6
  export declare const select: () => $64$luvio_engine_FragmentSelection;
7
7
  export declare function equals(existing: PaymentRunBatchFilterCriteriaInputRepresentationsNormalized, incoming: PaymentRunBatchFilterCriteriaInputRepresentationsNormalized): boolean;
8
- export declare function deepFreeze(input: PaymentRunBatchFilterCriteriaInputRepresentations): void;
9
8
  export declare const ingest: $64$luvio_engine_ResourceIngest;
10
9
  export declare function getTypeCacheKeys(luvio: $64$luvio_engine_Luvio, input: PaymentRunBatchFilterCriteriaInputRepresentations, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): $64$luvio_engine_DurableStoreKeyMetadataMap;
11
10
  /**
@@ -6,7 +6,6 @@ export declare const RepresentationType: string;
6
6
  export declare function normalize(input: PaymentsBatchSchedulerInputRepresentation, existing: PaymentsBatchSchedulerInputRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): PaymentsBatchSchedulerInputRepresentationNormalized;
7
7
  export declare const select: () => $64$luvio_engine_FragmentSelection;
8
8
  export declare function equals(existing: PaymentsBatchSchedulerInputRepresentationNormalized, incoming: PaymentsBatchSchedulerInputRepresentationNormalized): boolean;
9
- export declare function deepFreeze(input: PaymentsBatchSchedulerInputRepresentation): void;
10
9
  export declare const ingest: $64$luvio_engine_ResourceIngest;
11
10
  export declare function getTypeCacheKeys(luvio: $64$luvio_engine_Luvio, input: PaymentsBatchSchedulerInputRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): $64$luvio_engine_DurableStoreKeyMetadataMap;
12
11
  /**
@@ -6,7 +6,6 @@ export declare const RepresentationType: string;
6
6
  export declare function normalize(input: PaymentsBatchSchedulerInputWrapperRepresentation, existing: PaymentsBatchSchedulerInputWrapperRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): PaymentsBatchSchedulerInputWrapperRepresentationNormalized;
7
7
  export declare const select: () => $64$luvio_engine_FragmentSelection;
8
8
  export declare function equals(existing: PaymentsBatchSchedulerInputWrapperRepresentationNormalized, incoming: PaymentsBatchSchedulerInputWrapperRepresentationNormalized): boolean;
9
- export declare function deepFreeze(input: PaymentsBatchSchedulerInputWrapperRepresentation): void;
10
9
  export declare const ingest: $64$luvio_engine_ResourceIngest;
11
10
  export declare function getTypeCacheKeys(luvio: $64$luvio_engine_Luvio, input: PaymentsBatchSchedulerInputWrapperRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): $64$luvio_engine_DurableStoreKeyMetadataMap;
12
11
  /**
@@ -16,7 +16,6 @@ export declare function keyBuilderFromType_StructuredKey(luvio: $64$luvio_engine
16
16
  export declare function normalize(input: PaymentsBatchSchedulerOutputRepresentation, existing: PaymentsBatchSchedulerOutputRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): PaymentsBatchSchedulerOutputRepresentationNormalized;
17
17
  export declare const select: () => $64$luvio_engine_BaseFragment;
18
18
  export declare function equals(existing: PaymentsBatchSchedulerOutputRepresentationNormalized, incoming: PaymentsBatchSchedulerOutputRepresentationNormalized): boolean;
19
- export declare function deepFreeze(input: PaymentsBatchSchedulerOutputRepresentation): void;
20
19
  export declare const ingest: $64$luvio_engine_ResourceIngest;
21
20
  export declare function getTypeCacheKeys(luvio: $64$luvio_engine_Luvio, input: PaymentsBatchSchedulerOutputRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): $64$luvio_engine_DurableStoreKeyMetadataMap;
22
21
  /**
@@ -5,7 +5,6 @@ export declare const RepresentationType: string;
5
5
  export declare function normalize(input: ScheduleOptionsInputRepresentation, existing: ScheduleOptionsInputRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): ScheduleOptionsInputRepresentationNormalized;
6
6
  export declare const select: () => $64$luvio_engine_FragmentSelection;
7
7
  export declare function equals(existing: ScheduleOptionsInputRepresentationNormalized, incoming: ScheduleOptionsInputRepresentationNormalized): boolean;
8
- export declare function deepFreeze(input: ScheduleOptionsInputRepresentation): void;
9
8
  export declare const ingest: $64$luvio_engine_ResourceIngest;
10
9
  export declare function getTypeCacheKeys(luvio: $64$luvio_engine_Luvio, input: ScheduleOptionsInputRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): $64$luvio_engine_DurableStoreKeyMetadataMap;
11
10
  /**
@@ -5,7 +5,6 @@ export declare const RepresentationType: string;
5
5
  export declare function normalize(input: ScheduleOptionsInputRepresentationForInvoice, existing: ScheduleOptionsInputRepresentationForInvoiceNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): ScheduleOptionsInputRepresentationForInvoiceNormalized;
6
6
  export declare const select: () => $64$luvio_engine_FragmentSelection;
7
7
  export declare function equals(existing: ScheduleOptionsInputRepresentationForInvoiceNormalized, incoming: ScheduleOptionsInputRepresentationForInvoiceNormalized): boolean;
8
- export declare function deepFreeze(input: ScheduleOptionsInputRepresentationForInvoice): void;
9
8
  export declare const ingest: $64$luvio_engine_ResourceIngest;
10
9
  export declare function getTypeCacheKeys(luvio: $64$luvio_engine_Luvio, input: ScheduleOptionsInputRepresentationForInvoice, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): $64$luvio_engine_DurableStoreKeyMetadataMap;
11
10
  /**
@@ -1,11 +1,5 @@
1
1
  import { NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata } from '@luvio/engine';
2
- export declare const ObjectFreeze: {
3
- <T extends Function>(f: T): T;
4
- <T_1 extends {
5
- [idx: string]: object | U | null | undefined;
6
- }, U extends string | number | bigint | boolean | symbol>(o: T_1): Readonly<T_1>;
7
- <T_2>(o: T_2): Readonly<T_2>;
8
- }, ObjectKeys: {
2
+ export declare const ObjectKeys: {
9
3
  (o: object): string[];
10
4
  (o: {}): string[];
11
5
  }, ObjectCreate: {
@@ -31,7 +25,6 @@ export declare function equalsArray<U, V extends U[]>(a: V, b: V, equalsItem: (i
31
25
  export declare function equalsObject<U, V extends {
32
26
  [key: string]: U;
33
27
  }>(a: V, b: V, equalsProp: (propA: U, propB: U) => boolean | void): boolean;
34
- export declare function deepFreeze(value: any): void;
35
28
  export declare function createLink(ref: string | $64$luvio_engine_NormalizedKeyMetadata): {
36
29
  __ref: string;
37
30
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salesforce/lds-adapters-revenue-billing-batch",
3
- "version": "1.134.7",
3
+ "version": "1.134.8",
4
4
  "license": "SEE LICENSE IN LICENSE.txt",
5
5
  "description": "This API family is meant for all APIs required for Billing Batch.",
6
6
  "main": "dist/es/es2018/revenue-billing-batch.js",
package/sfdc/index.js CHANGED
@@ -13,10 +13,10 @@
13
13
  */
14
14
  /* proxy-compat-disable */
15
15
  import { withDefaultLuvio } from 'force/ldsEngine';
16
- import { serializeStructuredKey, StoreKeyMap } from 'force/luvioEngine';
16
+ import { serializeStructuredKey, StoreKeyMap, deepFreeze } from 'force/luvioEngine';
17
17
 
18
18
  const { hasOwnProperty: ObjectPrototypeHasOwnProperty } = Object.prototype;
19
- const { keys: ObjectKeys$1, freeze: ObjectFreeze$1, create: ObjectCreate$1 } = Object;
19
+ const { keys: ObjectKeys, create: ObjectCreate } = Object;
20
20
  const { isArray: ArrayIsArray$1 } = Array;
21
21
  /**
22
22
  * Validates an adapter config is well-formed.
@@ -40,7 +40,7 @@ function validateConfig(config, adapter, oneOf) {
40
40
  throw new TypeError(`adapter ${displayName} does not yet support ${unsupported.sort().join(', ')}`);
41
41
  }
42
42
  const supported = required.concat(optional);
43
- if (ObjectKeys$1(config).some(key => !supported.includes(key))) {
43
+ if (ObjectKeys(config).some(key => !supported.includes(key))) {
44
44
  throw new TypeError(`adapter ${displayName} configuration supports only ${supported.sort().join(', ')}`);
45
45
  }
46
46
  }
@@ -52,27 +52,8 @@ function areRequiredParametersPresent(config, configPropertyNames) {
52
52
  }
53
53
  const keyPrefix = 'BillingBatch';
54
54
 
55
- const { freeze: ObjectFreeze, keys: ObjectKeys, create: ObjectCreate, assign: ObjectAssign } = Object;
56
55
  const { isArray: ArrayIsArray } = Array;
57
56
  const { stringify: JSONStringify } = JSON;
58
- function deepFreeze$3(value) {
59
- // No need to freeze primitives
60
- if (typeof value !== 'object' || value === null) {
61
- return;
62
- }
63
- if (ArrayIsArray(value)) {
64
- for (let i = 0, len = value.length; i < len; i += 1) {
65
- deepFreeze$3(value[i]);
66
- }
67
- }
68
- else {
69
- const keys = ObjectKeys(value);
70
- for (let i = 0, len = keys.length; i < len; i += 1) {
71
- deepFreeze$3(value[keys[i]]);
72
- }
73
- }
74
- ObjectFreeze(value);
75
- }
76
57
  function createLink(ref) {
77
58
  return {
78
59
  __ref: serializeStructuredKey(ref),
@@ -170,9 +151,6 @@ function validate$4(obj, path = 'BillingBatchSchedulerRepresentation') {
170
151
  })();
171
152
  return v_error === undefined ? null : v_error;
172
153
  }
173
- function deepFreeze$2(input) {
174
- ObjectFreeze(input);
175
- }
176
154
 
177
155
  const TTL$1 = 1000;
178
156
  const VERSION$1 = "15c358b0b4903143c526f63f4010b958";
@@ -219,11 +197,6 @@ function equals$1(existing, incoming) {
219
197
  }
220
198
  return true;
221
199
  }
222
- function deepFreeze$1(input) {
223
- const input_billingBatchScheduler = input.billingBatchScheduler;
224
- deepFreeze$2(input_billingBatchScheduler);
225
- ObjectFreeze(input);
226
- }
227
200
  const ingest$1 = function InvoicesBatchSchedulerOutputRepresentationIngest(input, path, luvio, store, timestamp) {
228
201
  if (process.env.NODE_ENV !== 'production') {
229
202
  const validateError = validate$3(input);
@@ -240,7 +213,6 @@ const ingest$1 = function InvoicesBatchSchedulerOutputRepresentationIngest(input
240
213
  propertyName: path.propertyName,
241
214
  ttl: ttlToUse
242
215
  });
243
- deepFreeze$1(input);
244
216
  if (existingRecord === undefined || equals$1(existingRecord, incomingRecord) === false) {
245
217
  luvio.storePublish(key, incomingRecord);
246
218
  }
@@ -287,6 +259,7 @@ function ingestSuccess$1(luvio, resourceParams, response) {
287
259
  throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
288
260
  }
289
261
  }
262
+ deepFreeze(snapshot.data);
290
263
  return snapshot;
291
264
  }
292
265
  function createResourceRequest$1(config) {
@@ -350,7 +323,7 @@ function buildNetworkSnapshot$1(luvio, config, options) {
350
323
  return luvio.storeBroadcast().then(() => snapshot);
351
324
  }, () => getResponseCacheKeys$1(luvio, resourceParams, response.body));
352
325
  }, (response) => {
353
- deepFreeze$3(response);
326
+ deepFreeze(response);
354
327
  throw response;
355
328
  });
356
329
  }
@@ -492,11 +465,6 @@ function equals(existing, incoming) {
492
465
  }
493
466
  return true;
494
467
  }
495
- function deepFreeze(input) {
496
- const input_billingBatchScheduler = input.billingBatchScheduler;
497
- deepFreeze$2(input_billingBatchScheduler);
498
- ObjectFreeze(input);
499
- }
500
468
  const ingest = function PaymentsBatchSchedulerOutputRepresentationIngest(input, path, luvio, store, timestamp) {
501
469
  if (process.env.NODE_ENV !== 'production') {
502
470
  const validateError = validate(input);
@@ -513,7 +481,6 @@ const ingest = function PaymentsBatchSchedulerOutputRepresentationIngest(input,
513
481
  propertyName: path.propertyName,
514
482
  ttl: ttlToUse
515
483
  });
516
- deepFreeze(input);
517
484
  if (existingRecord === undefined || equals(existingRecord, incomingRecord) === false) {
518
485
  luvio.storePublish(key, incomingRecord);
519
486
  }
@@ -560,6 +527,7 @@ function ingestSuccess(luvio, resourceParams, response) {
560
527
  throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
561
528
  }
562
529
  }
530
+ deepFreeze(snapshot.data);
563
531
  return snapshot;
564
532
  }
565
533
  function createResourceRequest(config) {
@@ -623,7 +591,7 @@ function buildNetworkSnapshot(luvio, config, options) {
623
591
  return luvio.storeBroadcast().then(() => snapshot);
624
592
  }, () => getResponseCacheKeys(luvio, resourceParams, response.body));
625
593
  }, (response) => {
626
- deepFreeze$3(response);
594
+ deepFreeze(response);
627
595
  throw response;
628
596
  });
629
597
  }
@@ -659,4 +627,4 @@ withDefaultLuvio((luvio) => {
659
627
  });
660
628
 
661
629
  export { createInvoicesBatchScheduler, createPaymentsBatchScheduler };
662
- // version: 1.134.7-ed0df45ef
630
+ // version: 1.134.8-c3d6d2cfc