@magmaprotocol/magma-clmm-sdk 0.5.48 → 0.5.49
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 +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -2599,7 +2599,7 @@ var BinMath = class {
|
|
|
2599
2599
|
static getBinIdFromPrice(price, binStep, decimalsA, decimalsB) {
|
|
2600
2600
|
const twoDec = new Decimal6(2);
|
|
2601
2601
|
const tenDec = new Decimal6(10);
|
|
2602
|
-
const realid = get_real_id_from_price_x128(new Decimal6(price).mul(tenDec.pow(decimalsB -
|
|
2602
|
+
const realid = get_real_id_from_price_x128(new Decimal6(price).mul(tenDec.pow(decimalsB - decimalsA)).mul(twoDec.pow(128)).toDecimalPlaces(0).toString(), binStep);
|
|
2603
2603
|
return realid;
|
|
2604
2604
|
}
|
|
2605
2605
|
};
|