@meteora-ag/dlmm 1.0.49-rc.0 → 1.0.49-rc.2

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 CHANGED
@@ -10552,7 +10552,9 @@ var DLMM = class {
10552
10552
  tokensInvolved.push(this.lbPair.rewardInfos[i].mint);
10553
10553
  }
10554
10554
  }
10555
- positions = positions.filter(({ positionData: { feeX, feeY, rewardOne, rewardTwo } }) => !feeX.isZero() || !feeY.isZero() || !rewardOne.isZero() || !rewardTwo.isZero());
10555
+ positions = positions.filter(
10556
+ ({ positionData: { feeX, feeY, rewardOne, rewardTwo } }) => !feeX.isZero() || !feeY.isZero() || !rewardOne.isZero() || !rewardTwo.isZero()
10557
+ );
10556
10558
  const feeOwners = [
10557
10559
  .../* @__PURE__ */ new Set([
10558
10560
  owner.toBase58(),
@@ -10736,7 +10738,7 @@ var DLMM = class {
10736
10738
  }).add(syncWithMarketPriceTx);
10737
10739
  }
10738
10740
  async getMaxPriceInBinArrays(binArrayAccounts) {
10739
- const sortedBinArrays = binArrayAccounts.sort(
10741
+ const sortedBinArrays = [...binArrayAccounts].sort(
10740
10742
  ({ account: { index: indexA } }, { account: { index: indexB } }) => indexA.toNumber() - indexB.toNumber()
10741
10743
  );
10742
10744
  let count = sortedBinArrays.length - 1;
@@ -10744,7 +10746,7 @@ var DLMM = class {
10744
10746
  while (count >= 0) {
10745
10747
  const binArray = sortedBinArrays[count];
10746
10748
  if (binArray) {
10747
- const bins = binArray.account.bins.reverse();
10749
+ const bins = binArray.account.bins;
10748
10750
  if (bins.every(({ amountX }) => amountX.isZero())) {
10749
10751
  count--;
10750
10752
  } else {