@depay/widgets 12.3.17 → 12.3.18

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.
@@ -27227,7 +27227,7 @@ var getPaymentsAccountData = /*#__PURE__*/function () {
27227
27227
  }();
27228
27228
  var getNonce = /*#__PURE__*/function () {
27229
27229
  var _ref6 = _asyncToGenerator( /*#__PURE__*/regenerator.mark(function _callee3(_ref5) {
27230
- var blockchain, transaction, account, wallet, _transaction$nonce, paymentsAccountData;
27230
+ var blockchain, transaction, account, wallet, _transaction$nonce, _transaction$nonce2, paymentsAccountData;
27231
27231
  return regenerator.wrap(function _callee3$(_context3) {
27232
27232
  while (1) switch (_context3.prev = _context3.next) {
27233
27233
  case 0:
@@ -27257,27 +27257,33 @@ var getNonce = /*#__PURE__*/function () {
27257
27257
  case 10:
27258
27258
  return _context3.abrupt("return", _context3.sent.toString());
27259
27259
  case 11:
27260
- _context3.next = 22;
27260
+ _context3.next = 24;
27261
27261
  break;
27262
27262
  case 13:
27263
27263
  if (!supported.solana.includes(blockchain)) {
27264
- _context3.next = 22;
27264
+ _context3.next = 24;
27265
27265
  break;
27266
27266
  }
27267
- _context3.next = 16;
27267
+ if (!(transaction && transaction !== null && transaction !== void 0 && transaction.nonce)) {
27268
+ _context3.next = 16;
27269
+ break;
27270
+ }
27271
+ return _context3.abrupt("return", transaction === null || transaction === void 0 || (_transaction$nonce2 = transaction.nonce) === null || _transaction$nonce2 === void 0 ? void 0 : _transaction$nonce2.toString());
27272
+ case 16:
27273
+ _context3.next = 18;
27268
27274
  return getPaymentsAccountData({
27269
27275
  account: account
27270
27276
  });
27271
- case 16:
27277
+ case 18:
27272
27278
  paymentsAccountData = _context3.sent;
27273
27279
  if (!paymentsAccountData) {
27274
- _context3.next = 21;
27280
+ _context3.next = 23;
27275
27281
  break;
27276
27282
  }
27277
27283
  return _context3.abrupt("return", paymentsAccountData.nonce.toString());
27278
- case 21:
27284
+ case 23:
27279
27285
  return _context3.abrupt("return", '0');
27280
- case 22:
27286
+ case 24:
27281
27287
  case "end":
27282
27288
  return _context3.stop();
27283
27289
  }