@0dotxyz/p0-ts-sdk 2.3.0-alpha.6 → 2.3.0-alpha.7

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.cjs CHANGED
@@ -61421,6 +61421,12 @@ async function buildCandidates2(req, apiConfig) {
61421
61421
  transaction: {
61422
61422
  userPublicKey: req.taker.toBytes(),
61423
61423
  outputAccount: req.destinationTokenAccount.toBytes(),
61424
+ // Keep a wSOL output wrapped in the destination ATA (the analog of
61425
+ // Jupiter's `wrapAndUnwrapSol: false`). Our flashloan flows consume the
61426
+ // output with a subsequent marginfi ix built with `wrapAndUnwrapSol:
61427
+ // false`, so the wSOL must NOT be unwrapped to native lamports. Ignored
61428
+ // by Titan when the output mint isn't wSOL.
61429
+ outputWsol: true,
61424
61430
  titanSwapVersion: 3 /* V3 */,
61425
61431
  ...fee !== void 0 && feeAccount ? { feeBps: fee, feeAccount: new web3_js.PublicKey(feeAccount).toBytes() } : {}
61426
61432
  },
@@ -61801,7 +61807,7 @@ async function buildRepayWithCollatFlashloanTx({
61801
61807
  const swapNeeded = !repayOpts.repayBank.mint.equals(withdrawOpts.withdrawBank.mint);
61802
61808
  let amountToRepay = swapNeeded ? 0 : withdrawOpts.withdrawAmount;
61803
61809
  let swapInstructions = [];
61804
- const setupInstructions = [];
61810
+ let setupInstructions = [];
61805
61811
  let swapLookupTables = [];
61806
61812
  let swapQuote;
61807
61813
  let sizeConstraintUsed = 0;
@@ -62014,6 +62020,7 @@ async function buildRepayWithCollatFlashloanTx({
62014
62020
  );
62015
62021
  amountToRepay = outAmount > repayOpts.totalPositionAmount ? repayOpts.totalPositionAmount : outAmountThreshold;
62016
62022
  swapInstructions = engineResult.swapInstructions;
62023
+ setupInstructions = engineResult.setupInstructions;
62017
62024
  swapLookupTables = engineResult.swapLuts;
62018
62025
  swapQuote = engineResult.quoteResponse;
62019
62026
  }