@scallop-io/sui-scallop-sdk 0.46.34 → 0.46.35

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.
package/dist/index.js CHANGED
@@ -5650,16 +5650,17 @@ var generateReferralQuickMethod = ({
5650
5650
  const rewardCoin = txBlock.claimReferralRevenue(veScaKey, coinName);
5651
5651
  objToTransfer.push(rewardCoin);
5652
5652
  } else {
5653
- const coins = await builder.suiKit.suiInteractor.selectCoins(
5654
- sender,
5655
- Infinity,
5656
- builder.utils.parseCoinType(coinName)
5657
- );
5658
5653
  const rewardCoin = txBlock.claimReferralRevenue(veScaKey, coinName);
5659
- if (coins.length > 0) {
5654
+ try {
5655
+ const coins = await builder.suiKit.suiInteractor.selectCoins(
5656
+ sender,
5657
+ Infinity,
5658
+ builder.utils.parseCoinType(coinName)
5659
+ );
5660
5660
  txBlock.mergeCoins(rewardCoin, coins);
5661
+ } finally {
5662
+ objToTransfer.push(rewardCoin);
5661
5663
  }
5662
- objToTransfer.push(rewardCoin);
5663
5664
  }
5664
5665
  }
5665
5666
  if (objToTransfer.length > 0) {