From 05af84196eb49dd7b81fe78efc8f75f815ca602f Mon Sep 17 00:00:00 2001 From: Ben Wolski <570819+benwolski@users.noreply.github.com> Date: Thu, 5 Jun 2025 15:35:59 -0400 Subject: [PATCH] fix bound limit math --- package.json | 2 +- src/pool.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 18b470c..e12491c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@crocswap-libs/sdk", - "version": "2.0.14", + "version": "2.0.15", "description": "🛠🐊🛠 An SDK for building applications on top of CrocSwap", "author": "Ben Wolski ", "repository": "https://github.com/CrocSwap/sdk.git", diff --git a/src/pool.ts b/src/pool.ts index 3af72aa..347ab8d 100644 --- a/src/pool.ts +++ b/src/pool.ts @@ -227,8 +227,8 @@ export class CrocPoolView { } } - return this.untransformLimits( - [Math.max(amplifyLower, boundLower), Math.min(amplifyUpper, boundUpper)]) + return this.untransformLimits( + [Math.min(amplifyLower, boundLower), Math.max(amplifyUpper, boundUpper)]) } private rangeToPrice (range: TickRange): PriceRange {