@tap-payments/auth-jsconnect 2.8.37-test → 2.8.38-test

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.
@@ -228,10 +228,10 @@ export var verifyTaxLeadOTP = createAsyncThunk('verifyTaxLeadOTP', function (par
228
228
  export var updateTaxInfo = createAsyncThunk('updateTaxInfo', function (_a, thunkApi) {
229
229
  var formData = _a.formData, originalFormData = _a.originalFormData, isDirty = _a.isDirty;
230
230
  return __awaiter(void 0, void 0, void 0, function () {
231
- var _b, settings, tax, _c, entity, recipient, _d, id, data_status, documents, isTaxNumberNonEditable, isConfirmPolicyNonEditable, isDocumentsNonEditable, document, vatId, confirmPolicy, documentId, data, requestBody, documentBody, _e, documentBody, _f;
232
- var _g, _h;
233
- return __generator(this, function (_j) {
234
- switch (_j.label) {
231
+ var _b, settings, tax, _c, entity, recipient, _d, id, data_status, documents, isTaxNumberNonEditable, isConfirmPolicyNonEditable, isDocumentsNonEditable, document, vatId, confirmPolicy, documentId, data, requestBody, documentBody, documentData, documentBody, documentData;
232
+ var _e, _f;
233
+ return __generator(this, function (_g) {
234
+ switch (_g.label) {
235
235
  case 0:
236
236
  _b = thunkApi.getState(), settings = _b.settings, tax = _b.tax;
237
237
  _c = tax.data.verify.responseBody || {}, entity = _c.entity, recipient = _c.recipient;
@@ -249,8 +249,8 @@ export var updateTaxInfo = createAsyncThunk('updateTaxInfo', function (_a, thunk
249
249
  if (!isDirty) return [3, 2];
250
250
  return [4, API.entityService.updateEntityInfo(requestBody)];
251
251
  case 1:
252
- data = _j.sent();
253
- _j.label = 2;
252
+ data = _g.sent();
253
+ _g.label = 2;
254
254
  case 2:
255
255
  if (!(!isDocumentsNonEditable && (documentId || []).length > 0)) return [3, 6];
256
256
  if (!(document === null || document === void 0 ? void 0 : document.id)) return [3, 4];
@@ -258,10 +258,10 @@ export var updateTaxInfo = createAsyncThunk('updateTaxInfo', function (_a, thunk
258
258
  id: document === null || document === void 0 ? void 0 : document.id,
259
259
  images: documentId
260
260
  };
261
- _e = data;
262
261
  return [4, API.documentService.addFilesToExistingDocument(documentBody)];
263
262
  case 3:
264
- _e.documentData = _j.sent();
263
+ documentData = _g.sent();
264
+ data = __assign(__assign({}, data), { documentData: documentData });
265
265
  return [3, 6];
266
266
  case 4:
267
267
  documentBody = {
@@ -273,14 +273,14 @@ export var updateTaxInfo = createAsyncThunk('updateTaxInfo', function (_a, thunk
273
273
  }
274
274
  ]
275
275
  };
276
- _f = data;
277
276
  return [4, API.documentService.updateDocumentInfo(documentBody)];
278
277
  case 5:
279
- _f.documentData = _j.sent();
280
- _j.label = 6;
278
+ documentData = _g.sent();
279
+ data = __assign(__assign({}, data), { documentData: documentData });
280
+ _g.label = 6;
281
281
  case 6:
282
282
  thunkApi.dispatch(handleNextScreenStep());
283
- (_h = (_g = settings.data.appConfig).onStepCompleted) === null || _h === void 0 ? void 0 : _h.call(_g, settings.data.activeScreen.name, requestBody);
283
+ (_f = (_e = settings.data.appConfig).onStepCompleted) === null || _f === void 0 ? void 0 : _f.call(_e, settings.data.activeScreen.name, requestBody);
284
284
  return [2, { data: data, formData: originalFormData }];
285
285
  }
286
286
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tap-payments/auth-jsconnect",
3
- "version": "2.8.37-test",
3
+ "version": "2.8.38-test",
4
4
  "description": "connect library, auth",
5
5
  "private": false,
6
6
  "main": "build/index.js",