@rango-dev/queue-manager-rango-preset 0.1.13-next.13 → 0.1.13-next.15

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.
@@ -498,7 +498,7 @@ var PrettyError = /*#__PURE__*/function (_Error) {
498
498
  return _this;
499
499
  }
500
500
  PrettyError.isPrettyError = function isPrettyError(obj) {
501
- return obj instanceof PrettyError || Object.prototype.hasOwnProperty('_isPrettyError');
501
+ return obj instanceof PrettyError || Object.prototype.hasOwnProperty.call(obj, '_isPrettyError');
502
502
  };
503
503
  var _proto = PrettyError.prototype;
504
504
  _proto.getErrorDetail = function getErrorDetail() {
@@ -1131,25 +1131,30 @@ function _getChainId() {
1131
1131
  return _regeneratorRuntime().wrap(function _callee$(_context) {
1132
1132
  while (1) switch (_context.prev = _context.next) {
1133
1133
  case 0:
1134
- _context.next = 2;
1134
+ _context.prev = 0;
1135
+ _context.next = 3;
1135
1136
  return provider.request({
1136
1137
  method: 'eth_chainId'
1137
1138
  });
1138
- case 2:
1139
+ case 3:
1139
1140
  _context.t0 = _context.sent;
1140
1141
  if (_context.t0) {
1141
- _context.next = 5;
1142
+ _context.next = 6;
1142
1143
  break;
1143
1144
  }
1144
1145
  _context.t0 = provider == null ? void 0 : provider.chainId;
1145
- case 5:
1146
+ case 6:
1146
1147
  chainId = _context.t0;
1147
1148
  return _context.abrupt("return", chainId);
1148
- case 7:
1149
+ case 10:
1150
+ _context.prev = 10;
1151
+ _context.t1 = _context["catch"](0);
1152
+ return _context.abrupt("return", provider == null ? void 0 : provider.chainId);
1153
+ case 13:
1149
1154
  case "end":
1150
1155
  return _context.stop();
1151
1156
  }
1152
- }, _callee);
1157
+ }, _callee, null, [[0, 10]]);
1153
1158
  }));
1154
1159
  return _getChainId.apply(this, arguments);
1155
1160
  }
@@ -1437,7 +1442,7 @@ function isRequiredWalletConnected(swap, getState) {
1437
1442
  var matched = connectedAccounts.some(function (account) {
1438
1443
  var _readAccountAddress = readAccountAddress(account),
1439
1444
  accountAddress = _readAccountAddress.address;
1440
- return address === accountAddress;
1445
+ return address.toLocaleLowerCase() === accountAddress.toLocaleLowerCase();
1441
1446
  });
1442
1447
  return {
1443
1448
  ok: matched,
@@ -1517,7 +1522,7 @@ function singTransaction(actions) {
1517
1522
  errorCode: extraMessageErrorCode
1518
1523
  });
1519
1524
  notifier(_extends({
1520
- eventType: 'contract_rejected'
1525
+ eventType: extraMessageErrorCode === 'REJECTED_BY_USER' ? 'contract_rejected' : 'smart_contract_call_failed'
1521
1526
  }, updateResult));
1522
1527
  failed();
1523
1528
  onFinish();
@@ -1563,7 +1568,7 @@ function singTransaction(actions) {
1563
1568
  errorCode: extraMessageErrorCode
1564
1569
  });
1565
1570
  notifier(_extends({
1566
- eventType: 'contract_rejected'
1571
+ eventType: extraMessageErrorCode === 'REJECTED_BY_USER' ? 'contract_rejected' : 'smart_contract_call_failed'
1567
1572
  }, updateResult));
1568
1573
  failed();
1569
1574
  onFinish();
@@ -1609,7 +1614,7 @@ function singTransaction(actions) {
1609
1614
  errorCode: extraMessageErrorCode
1610
1615
  });
1611
1616
  notifier(_extends({
1612
- eventType: 'contract_rejected'
1617
+ eventType: extraMessageErrorCode === 'REJECTED_BY_USER' ? 'contract_rejected' : 'smart_contract_call_failed'
1613
1618
  }, updateResult));
1614
1619
  failed();
1615
1620
  onFinish();
@@ -1659,7 +1664,7 @@ function singTransaction(actions) {
1659
1664
  errorCode: extraMessageErrorCode
1660
1665
  });
1661
1666
  notifier(_extends({
1662
- eventType: 'transfer_rejected'
1667
+ eventType: extraMessageErrorCode === 'REJECTED_BY_USER' ? 'transfer_rejected' : 'transfer_failed'
1663
1668
  }, updateResult));
1664
1669
  failed();
1665
1670
  onFinish();
@@ -1707,7 +1712,7 @@ function singTransaction(actions) {
1707
1712
  errorCode: extraMessageErrorCode
1708
1713
  });
1709
1714
  notifier(_extends({
1710
- eventType: 'smart_contract_call_failed'
1715
+ eventType: extraMessageErrorCode === 'REJECTED_BY_USER' ? 'contract_rejected' : 'smart_contract_call_failed'
1711
1716
  }, updateResult));
1712
1717
  failed();
1713
1718
  onFinish();