@kamino-finance/kliquidity-sdk 7.0.11 → 7.0.13
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/Kamino.d.ts.map +1 -1
- package/dist/Kamino.js +6 -0
- package/dist/Kamino.js.map +1 -1
- package/package.json +1 -1
- package/src/Kamino.ts +10 -0
package/package.json
CHANGED
package/src/Kamino.ts
CHANGED
|
@@ -2207,6 +2207,10 @@ export class Kamino {
|
|
|
2207
2207
|
console.log(`Could not find collateral info for token ${token.toString()}`);
|
|
2208
2208
|
continue;
|
|
2209
2209
|
}
|
|
2210
|
+
// if there already is a spot price for this token, skip it
|
|
2211
|
+
if (spotPrices[token.toString()]) {
|
|
2212
|
+
continue;
|
|
2213
|
+
}
|
|
2210
2214
|
spotPrices[token.toString()] = {
|
|
2211
2215
|
price: new Decimal(price),
|
|
2212
2216
|
name: getTokenNameFromCollateralInfo(collInfo),
|
|
@@ -2804,6 +2808,12 @@ export class Kamino {
|
|
|
2804
2808
|
{ pubkey: poolState.rewardInfos[2].tokenMint, isSigner: false, isWritable: true },
|
|
2805
2809
|
]);
|
|
2806
2810
|
}
|
|
2811
|
+
|
|
2812
|
+
const [poolTickArrayBitmap, _poolTickArrayBitmapBump] = PublicKey.findProgramAddressSync(
|
|
2813
|
+
[Buffer.from('pool_tick_array_bitmap_extension'), strategyState.strategy.pool.toBuffer()],
|
|
2814
|
+
this._raydiumService.getRaydiumProgramId()
|
|
2815
|
+
);
|
|
2816
|
+
withdrawIx.keys.push({ pubkey: poolTickArrayBitmap, isSigner: false, isWritable: true });
|
|
2807
2817
|
}
|
|
2808
2818
|
|
|
2809
2819
|
const res: WithdrawShares = { prerequisiteIxs: collectFeesAndRewardsIxns, withdrawIx };
|