@crypticdot/defituna-client 2.0.15 → 2.0.16
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 +16 -16
- package/dist/index.mjs +16 -16
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -8737,22 +8737,22 @@ var import_memo8 = require("@solana-program/memo");
|
|
|
8737
8737
|
var import_token_202214 = require("@solana-program/token-2022");
|
|
8738
8738
|
async function liquidatePositionOrcaInstructions(authority, tunaPosition, tunaConfig, mintA, mintB, vaultA, vaultB, whirlpool, withdrawPercent) {
|
|
8739
8739
|
const instructions = [];
|
|
8740
|
-
const
|
|
8740
|
+
const createFeeRecipientAtaAInstructions = await getCreateAtaInstructions(
|
|
8741
8741
|
void 0,
|
|
8742
8742
|
authority,
|
|
8743
8743
|
mintA.address,
|
|
8744
|
-
|
|
8744
|
+
tunaConfig.data.feeRecipient,
|
|
8745
8745
|
mintA.programAddress
|
|
8746
8746
|
);
|
|
8747
|
-
instructions.push(...
|
|
8748
|
-
const
|
|
8747
|
+
instructions.push(...createFeeRecipientAtaAInstructions.init);
|
|
8748
|
+
const createFeeRecipientAtaBInstructions = await getCreateAtaInstructions(
|
|
8749
8749
|
void 0,
|
|
8750
8750
|
authority,
|
|
8751
8751
|
mintB.address,
|
|
8752
|
-
|
|
8752
|
+
tunaConfig.data.feeRecipient,
|
|
8753
8753
|
mintB.programAddress
|
|
8754
8754
|
);
|
|
8755
|
-
instructions.push(...
|
|
8755
|
+
instructions.push(...createFeeRecipientAtaBInstructions.init);
|
|
8756
8756
|
const ix = await liquidatePositionOrcaInstruction(
|
|
8757
8757
|
authority,
|
|
8758
8758
|
tunaPosition,
|
|
@@ -8765,8 +8765,8 @@ async function liquidatePositionOrcaInstructions(authority, tunaPosition, tunaCo
|
|
|
8765
8765
|
withdrawPercent
|
|
8766
8766
|
);
|
|
8767
8767
|
instructions.push(ix);
|
|
8768
|
-
instructions.push(...
|
|
8769
|
-
instructions.push(...
|
|
8768
|
+
instructions.push(...createFeeRecipientAtaAInstructions.cleanup);
|
|
8769
|
+
instructions.push(...createFeeRecipientAtaBInstructions.cleanup);
|
|
8770
8770
|
return instructions;
|
|
8771
8771
|
}
|
|
8772
8772
|
async function liquidatePositionOrcaInstruction(authority, tunaPosition, tunaConfig, mintA, mintB, vaultA, vaultB, whirlpool, withdrawPercent) {
|
|
@@ -8878,22 +8878,22 @@ var import_memo9 = require("@solana-program/memo");
|
|
|
8878
8878
|
var import_token_202215 = require("@solana-program/token-2022");
|
|
8879
8879
|
async function liquidatePositionFusionInstructions(authority, tunaPosition, tunaConfig, mintA, mintB, vaultA, vaultB, whirlpool, withdrawPercent) {
|
|
8880
8880
|
const instructions = [];
|
|
8881
|
-
const
|
|
8881
|
+
const createFeeRecipientAtaAInstructions = await getCreateAtaInstructions(
|
|
8882
8882
|
void 0,
|
|
8883
8883
|
authority,
|
|
8884
8884
|
mintA.address,
|
|
8885
|
-
|
|
8885
|
+
tunaConfig.data.feeRecipient,
|
|
8886
8886
|
mintA.programAddress
|
|
8887
8887
|
);
|
|
8888
|
-
instructions.push(...
|
|
8889
|
-
const
|
|
8888
|
+
instructions.push(...createFeeRecipientAtaAInstructions.init);
|
|
8889
|
+
const createFeeRecipientAtaBInstructions = await getCreateAtaInstructions(
|
|
8890
8890
|
void 0,
|
|
8891
8891
|
authority,
|
|
8892
8892
|
mintB.address,
|
|
8893
|
-
|
|
8893
|
+
tunaConfig.data.feeRecipient,
|
|
8894
8894
|
mintB.programAddress
|
|
8895
8895
|
);
|
|
8896
|
-
instructions.push(...
|
|
8896
|
+
instructions.push(...createFeeRecipientAtaBInstructions.init);
|
|
8897
8897
|
const ix = await liquidatePositionFusionInstruction(
|
|
8898
8898
|
authority,
|
|
8899
8899
|
tunaPosition,
|
|
@@ -8906,8 +8906,8 @@ async function liquidatePositionFusionInstructions(authority, tunaPosition, tuna
|
|
|
8906
8906
|
withdrawPercent
|
|
8907
8907
|
);
|
|
8908
8908
|
instructions.push(ix);
|
|
8909
|
-
instructions.push(...
|
|
8910
|
-
instructions.push(...
|
|
8909
|
+
instructions.push(...createFeeRecipientAtaAInstructions.cleanup);
|
|
8910
|
+
instructions.push(...createFeeRecipientAtaBInstructions.cleanup);
|
|
8911
8911
|
return instructions;
|
|
8912
8912
|
}
|
|
8913
8913
|
async function liquidatePositionFusionInstruction(authority, tunaPosition, tunaConfig, mintA, mintB, vaultA, vaultB, fusionPool, withdrawPercent) {
|
package/dist/index.mjs
CHANGED
|
@@ -8920,22 +8920,22 @@ import { MEMO_PROGRAM_ADDRESS as MEMO_PROGRAM_ADDRESS8 } from "@solana-program/m
|
|
|
8920
8920
|
import { findAssociatedTokenPda as findAssociatedTokenPda14, TOKEN_2022_PROGRAM_ADDRESS as TOKEN_2022_PROGRAM_ADDRESS11 } from "@solana-program/token-2022";
|
|
8921
8921
|
async function liquidatePositionOrcaInstructions(authority, tunaPosition, tunaConfig, mintA, mintB, vaultA, vaultB, whirlpool, withdrawPercent) {
|
|
8922
8922
|
const instructions = [];
|
|
8923
|
-
const
|
|
8923
|
+
const createFeeRecipientAtaAInstructions = await getCreateAtaInstructions(
|
|
8924
8924
|
void 0,
|
|
8925
8925
|
authority,
|
|
8926
8926
|
mintA.address,
|
|
8927
|
-
|
|
8927
|
+
tunaConfig.data.feeRecipient,
|
|
8928
8928
|
mintA.programAddress
|
|
8929
8929
|
);
|
|
8930
|
-
instructions.push(...
|
|
8931
|
-
const
|
|
8930
|
+
instructions.push(...createFeeRecipientAtaAInstructions.init);
|
|
8931
|
+
const createFeeRecipientAtaBInstructions = await getCreateAtaInstructions(
|
|
8932
8932
|
void 0,
|
|
8933
8933
|
authority,
|
|
8934
8934
|
mintB.address,
|
|
8935
|
-
|
|
8935
|
+
tunaConfig.data.feeRecipient,
|
|
8936
8936
|
mintB.programAddress
|
|
8937
8937
|
);
|
|
8938
|
-
instructions.push(...
|
|
8938
|
+
instructions.push(...createFeeRecipientAtaBInstructions.init);
|
|
8939
8939
|
const ix = await liquidatePositionOrcaInstruction(
|
|
8940
8940
|
authority,
|
|
8941
8941
|
tunaPosition,
|
|
@@ -8948,8 +8948,8 @@ async function liquidatePositionOrcaInstructions(authority, tunaPosition, tunaCo
|
|
|
8948
8948
|
withdrawPercent
|
|
8949
8949
|
);
|
|
8950
8950
|
instructions.push(ix);
|
|
8951
|
-
instructions.push(...
|
|
8952
|
-
instructions.push(...
|
|
8951
|
+
instructions.push(...createFeeRecipientAtaAInstructions.cleanup);
|
|
8952
|
+
instructions.push(...createFeeRecipientAtaBInstructions.cleanup);
|
|
8953
8953
|
return instructions;
|
|
8954
8954
|
}
|
|
8955
8955
|
async function liquidatePositionOrcaInstruction(authority, tunaPosition, tunaConfig, mintA, mintB, vaultA, vaultB, whirlpool, withdrawPercent) {
|
|
@@ -9061,22 +9061,22 @@ import { MEMO_PROGRAM_ADDRESS as MEMO_PROGRAM_ADDRESS9 } from "@solana-program/m
|
|
|
9061
9061
|
import { findAssociatedTokenPda as findAssociatedTokenPda15, TOKEN_2022_PROGRAM_ADDRESS as TOKEN_2022_PROGRAM_ADDRESS12 } from "@solana-program/token-2022";
|
|
9062
9062
|
async function liquidatePositionFusionInstructions(authority, tunaPosition, tunaConfig, mintA, mintB, vaultA, vaultB, whirlpool, withdrawPercent) {
|
|
9063
9063
|
const instructions = [];
|
|
9064
|
-
const
|
|
9064
|
+
const createFeeRecipientAtaAInstructions = await getCreateAtaInstructions(
|
|
9065
9065
|
void 0,
|
|
9066
9066
|
authority,
|
|
9067
9067
|
mintA.address,
|
|
9068
|
-
|
|
9068
|
+
tunaConfig.data.feeRecipient,
|
|
9069
9069
|
mintA.programAddress
|
|
9070
9070
|
);
|
|
9071
|
-
instructions.push(...
|
|
9072
|
-
const
|
|
9071
|
+
instructions.push(...createFeeRecipientAtaAInstructions.init);
|
|
9072
|
+
const createFeeRecipientAtaBInstructions = await getCreateAtaInstructions(
|
|
9073
9073
|
void 0,
|
|
9074
9074
|
authority,
|
|
9075
9075
|
mintB.address,
|
|
9076
|
-
|
|
9076
|
+
tunaConfig.data.feeRecipient,
|
|
9077
9077
|
mintB.programAddress
|
|
9078
9078
|
);
|
|
9079
|
-
instructions.push(...
|
|
9079
|
+
instructions.push(...createFeeRecipientAtaBInstructions.init);
|
|
9080
9080
|
const ix = await liquidatePositionFusionInstruction(
|
|
9081
9081
|
authority,
|
|
9082
9082
|
tunaPosition,
|
|
@@ -9089,8 +9089,8 @@ async function liquidatePositionFusionInstructions(authority, tunaPosition, tuna
|
|
|
9089
9089
|
withdrawPercent
|
|
9090
9090
|
);
|
|
9091
9091
|
instructions.push(ix);
|
|
9092
|
-
instructions.push(...
|
|
9093
|
-
instructions.push(...
|
|
9092
|
+
instructions.push(...createFeeRecipientAtaAInstructions.cleanup);
|
|
9093
|
+
instructions.push(...createFeeRecipientAtaBInstructions.cleanup);
|
|
9094
9094
|
return instructions;
|
|
9095
9095
|
}
|
|
9096
9096
|
async function liquidatePositionFusionInstruction(authority, tunaPosition, tunaConfig, mintA, mintB, vaultA, vaultB, fusionPool, withdrawPercent) {
|
package/package.json
CHANGED