@scallop-io/sui-scallop-sdk 0.46.54 → 0.46.55

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@scallop-io/sui-scallop-sdk",
3
- "version": "0.46.54",
3
+ "version": "0.46.55",
4
4
  "description": "Typescript sdk for interacting with Scallop contract on SUI",
5
5
  "keywords": [
6
6
  "sui",
@@ -1,5 +1,5 @@
1
1
  import { TransactionBlock } from '@mysten/sui.js/transactions';
2
- import { SuiObjectArg, SuiTxBlock as SuiKitTxBlock } from '@scallop-io/sui-kit';
2
+ import { SuiTxBlock as SuiKitTxBlock } from '@scallop-io/sui-kit';
3
3
  import { coinIds } from 'src/constants';
4
4
  import { ScallopBuilder } from 'src/models';
5
5
  import {
@@ -43,7 +43,6 @@ const generateLoyaltyProgramQuickMethod: GenerateLoyaltyProgramQuickMethod = ({
43
43
  if (!veScaKey) throw new Error(`No veScaKey found for user ${sender}`);
44
44
 
45
45
  // claim the pending reward
46
- const toTransferObject: SuiObjectArg[] = [];
47
46
  const rewardCoin = txBlock.claimLoyaltyRevenue(veScaKey);
48
47
 
49
48
  // get existing sca coin to merge with
@@ -53,10 +52,7 @@ const generateLoyaltyProgramQuickMethod: GenerateLoyaltyProgramQuickMethod = ({
53
52
  coinIds.sca,
54
53
  requireSender(txBlock)
55
54
  );
56
-
57
- if (toTransferObject.length > 0) {
58
- txBlock.transferObjects(toTransferObject, sender);
59
- }
55
+ txBlock.transferObjects([rewardCoin], sender);
60
56
  },
61
57
  };
62
58
  };