@okta/okta-auth-js 6.3.0 → 6.3.1

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.
@@ -4455,11 +4455,11 @@ var TransactionManager = function () {
4455
4455
  if (!storage) {
4456
4456
  return null;
4457
4457
  }
4458
- var idxResponse = storage.getStorage();
4459
- if (!isRawIdxResponse(idxResponse)) {
4458
+ var storedValue = storage.getStorage();
4459
+ if (!storedValue || !isRawIdxResponse(storedValue.rawIdxResponse)) {
4460
4460
  return null;
4461
4461
  }
4462
- return idxResponse;
4462
+ return storedValue;
4463
4463
  }
4464
4464
  }, {
4465
4465
  key: "clearIdxResponse",
@@ -7492,13 +7492,13 @@ function remediate(_x, _x2, _x3) {
7492
7492
  function _remediate() {
7493
7493
  _remediate = _asyncToGenerator( _regeneratorRuntime.mark(function _callee(idxResponse, values, options) {
7494
7494
  var _context3;
7495
- var _idxResponse, neededToProceed, interactionCode, remediators, flow, terminal, messages, actionFromValues, actionFromOptions, actions, _iterator2, _step2, _loop, _ret, remediator, nextStep, _nextStep, name, data;
7495
+ var _idxResponse, neededToProceed, interactionCode, flow, terminal, messages, remediator, actionFromValues, actionFromOptions, actions, _iterator2, _step2, _loop, _ret, nextStep, _nextStep, name, data;
7496
7496
  return _regeneratorRuntime.wrap(function _callee$(_context5) {
7497
7497
  while (1) {
7498
7498
  switch (_context5.prev = _context5.next) {
7499
7499
  case 0:
7500
7500
  _idxResponse = idxResponse, neededToProceed = _idxResponse.neededToProceed, interactionCode = _idxResponse.interactionCode;
7501
- remediators = options.remediators, flow = options.flow;
7501
+ flow = options.flow;
7502
7502
  if (!interactionCode) {
7503
7503
  _context5.next = 4;
7504
7504
  break;
@@ -7519,15 +7519,16 @@ function _remediate() {
7519
7519
  messages: messages
7520
7520
  });
7521
7521
  case 8:
7522
+ remediator = getRemediator(neededToProceed, values, options);
7522
7523
  actionFromValues = getActionFromValues(values, idxResponse);
7523
7524
  actionFromOptions = options.actions || [];
7524
7525
  actions = _concatInstanceProperty(_context3 = []).call(_context3, _toConsumableArray(actionFromOptions), _toConsumableArray(actionFromValues && [actionFromValues] || []));
7525
7526
  if (!actions) {
7526
- _context5.next = 31;
7527
+ _context5.next = 32;
7527
7528
  break;
7528
7529
  }
7529
7530
  _iterator2 = _createForOfIteratorHelper(actions);
7530
- _context5.prev = 13;
7531
+ _context5.prev = 14;
7531
7532
  _loop = _regeneratorRuntime.mark(function _loop() {
7532
7533
  var action, valuesWithoutExecutedAction, optionsWithoutExecutedAction, remediationAction;
7533
7534
  return _regeneratorRuntime.wrap(function _loop$(_context4) {
@@ -7557,7 +7558,7 @@ function _remediate() {
7557
7558
  _context4.prev = 11;
7558
7559
  _context4.t0 = _context4["catch"](4);
7559
7560
  return _context4.abrupt("return", {
7560
- v: handleIdxError(_context4.t0, remediators)
7561
+ v: handleIdxError(_context4.t0, remediator)
7561
7562
  });
7562
7563
  case 14:
7563
7564
  if (!(action === 'cancel')) {
@@ -7595,7 +7596,7 @@ function _remediate() {
7595
7596
  _context4.prev = 26;
7596
7597
  _context4.t1 = _context4["catch"](19);
7597
7598
  return _context4.abrupt("return", {
7598
- v: handleIdxError(_context4.t1, remediators)
7599
+ v: handleIdxError(_context4.t1, remediator)
7599
7600
  });
7600
7601
  case 29:
7601
7602
  return _context4.abrupt("return", {
@@ -7609,35 +7610,34 @@ function _remediate() {
7609
7610
  }, _loop, null, [[4, 11], [19, 26]]);
7610
7611
  });
7611
7612
  _iterator2.s();
7612
- case 16:
7613
+ case 17:
7613
7614
  if ((_step2 = _iterator2.n()).done) {
7614
- _context5.next = 23;
7615
+ _context5.next = 24;
7615
7616
  break;
7616
7617
  }
7617
- return _context5.delegateYield(_loop(), "t0", 18);
7618
- case 18:
7618
+ return _context5.delegateYield(_loop(), "t0", 19);
7619
+ case 19:
7619
7620
  _ret = _context5.t0;
7620
7621
  if (!(_typeof(_ret) === "object")) {
7621
- _context5.next = 21;
7622
+ _context5.next = 22;
7622
7623
  break;
7623
7624
  }
7624
7625
  return _context5.abrupt("return", _ret.v);
7625
- case 21:
7626
- _context5.next = 16;
7626
+ case 22:
7627
+ _context5.next = 17;
7627
7628
  break;
7628
- case 23:
7629
- _context5.next = 28;
7629
+ case 24:
7630
+ _context5.next = 29;
7630
7631
  break;
7631
- case 25:
7632
- _context5.prev = 25;
7633
- _context5.t1 = _context5["catch"](13);
7632
+ case 26:
7633
+ _context5.prev = 26;
7634
+ _context5.t1 = _context5["catch"](14);
7634
7635
  _iterator2.e(_context5.t1);
7635
- case 28:
7636
- _context5.prev = 28;
7636
+ case 29:
7637
+ _context5.prev = 29;
7637
7638
  _iterator2.f();
7638
- return _context5.finish(28);
7639
- case 31:
7640
- remediator = getRemediator(neededToProceed, values, options);
7639
+ return _context5.finish(29);
7640
+ case 32:
7641
7641
  if (remediator) {
7642
7642
  _context5.next = 49;
7643
7643
  break;
@@ -7714,7 +7714,7 @@ function _remediate() {
7714
7714
  return _context5.stop();
7715
7715
  }
7716
7716
  }
7717
- }, _callee, null, [[13, 25, 28, 31], [35, 43], [57, 67]]);
7717
+ }, _callee, null, [[14, 26, 29, 32], [35, 43], [57, 67]]);
7718
7718
  }));
7719
7719
  return _remediate.apply(this, arguments);
7720
7720
  }
@@ -8671,7 +8671,7 @@ function createGlobalRequestInterceptor(sdk) {
8671
8671
  var OktaUserAgent = function () {
8672
8672
  function OktaUserAgent() {
8673
8673
  _classCallCheck(this, OktaUserAgent);
8674
- this.environments = ["okta-auth-js/".concat("6.3.0")];
8674
+ this.environments = ["okta-auth-js/".concat("6.3.1")];
8675
8675
  }
8676
8676
  _createClass(OktaUserAgent, [{
8677
8677
  key: "addEnvironment",
@@ -8689,7 +8689,7 @@ var OktaUserAgent = function () {
8689
8689
  }, {
8690
8690
  key: "getVersion",
8691
8691
  value: function getVersion() {
8692
- return "6.3.0";
8692
+ return "6.3.1";
8693
8693
  }
8694
8694
  }, {
8695
8695
  key: "maybeAddNodeEnvironment",