Skip to content

Commit bdaf62e

Browse files
committed
fix: collapse chained BigDecimal call in pricing.ts to satisfy prettier lint
1 parent 5ef0e66 commit bdaf62e

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

src/utils/pricing.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,7 @@ export function sqrtPriceX96ToTokenPrices(
1717

1818
const num = sqrtPriceX96.times(sqrtPriceX96).toBigDecimal()
1919
const denom = BigDecimal.fromString(Q192.toString())
20-
const price1 = num
21-
.div(denom)
22-
.times(exponentToBigDecimal(token0Decimals))
23-
.div(exponentToBigDecimal(token1Decimals))
20+
const price1 = num.div(denom).times(exponentToBigDecimal(token0Decimals)).div(exponentToBigDecimal(token1Decimals))
2421

2522
const price0 = safeDiv(BigDecimal.fromString('1'), price1)
2623
return [price0, price1]

0 commit comments

Comments
 (0)