@meteora-ag/cp-amm-sdk 1.0.8 → 1.0.9
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.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +11 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +11 -3
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -9928,7 +9928,7 @@ var CpAmm = class {
|
|
|
9928
9928
|
}
|
|
9929
9929
|
/**
|
|
9930
9930
|
* Builds a transaction to claim position fee rewards.
|
|
9931
|
-
* @param {
|
|
9931
|
+
* @param {ClaimPositionFeeParams2} params - Parameters for claiming position fee.
|
|
9932
9932
|
* @returns Transaction builder.
|
|
9933
9933
|
*/
|
|
9934
9934
|
claimPositionFee2(params) {
|
|
@@ -9948,14 +9948,22 @@ var CpAmm = class {
|
|
|
9948
9948
|
tokenBProgram
|
|
9949
9949
|
} = params;
|
|
9950
9950
|
const payer = feePayer != null ? feePayer : owner;
|
|
9951
|
+
let tokenAOwner = receiver;
|
|
9952
|
+
let tokenBOwner = receiver;
|
|
9953
|
+
if (tokenAMint.equals(NATIVE_MINT2)) {
|
|
9954
|
+
tokenAOwner = owner;
|
|
9955
|
+
}
|
|
9956
|
+
if (tokenBMint.equals(NATIVE_MINT2)) {
|
|
9957
|
+
tokenBOwner = owner;
|
|
9958
|
+
}
|
|
9951
9959
|
const {
|
|
9952
9960
|
tokenAAta: tokenAAccount,
|
|
9953
9961
|
tokenBAta: tokenBAccount,
|
|
9954
9962
|
instructions: preInstruction
|
|
9955
9963
|
} = yield this.prepareTokenAccounts({
|
|
9956
9964
|
payer,
|
|
9957
|
-
tokenAOwner
|
|
9958
|
-
tokenBOwner
|
|
9965
|
+
tokenAOwner,
|
|
9966
|
+
tokenBOwner,
|
|
9959
9967
|
tokenAMint,
|
|
9960
9968
|
tokenBMint,
|
|
9961
9969
|
tokenAProgram,
|