aboutsummaryrefslogtreecommitdiffstats
path: root/packages/asset-buyer/src/utils
diff options
context:
space:
mode:
authorSteve Klebanoff <steve.klebanoff@gmail.com>2019-01-17 06:16:49 +0800
committerSteve Klebanoff <steve.klebanoff@gmail.com>2019-01-17 06:16:49 +0800
commit466ec6b22a51f0a9d618f6091ce6f9f533118280 (patch)
tree433bf040b0e11666bb1429b569c941d5e677395b /packages/asset-buyer/src/utils
parenta58771844366d5fd331e6b46a8de596d17fa6632 (diff)
downloaddexon-0x-contracts-466ec6b22a51f0a9d618f6091ce6f9f533118280.tar.gz
dexon-0x-contracts-466ec6b22a51f0a9d618f6091ce6f9f533118280.tar.zst
dexon-0x-contracts-466ec6b22a51f0a9d618f6091ce6f9f533118280.zip
Change LiquidityForAssetData to return a BigNumber instead of a number to avoid losing precision
Diffstat (limited to 'packages/asset-buyer/src/utils')
-rw-r--r--packages/asset-buyer/src/utils/calculate_liquidity.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/asset-buyer/src/utils/calculate_liquidity.ts b/packages/asset-buyer/src/utils/calculate_liquidity.ts
index 910c756ac..a8d165b4b 100644
--- a/packages/asset-buyer/src/utils/calculate_liquidity.ts
+++ b/packages/asset-buyer/src/utils/calculate_liquidity.ts
@@ -28,7 +28,7 @@ export const calculateLiquidity = (ordersAndFillableAmounts: OrdersAndFillableAm
// Turn into regular numbers
return {
- tokensAvailableInBaseUnits: liquidityInBigNumbers.tokensAvailableInBaseUnits.toNumber(),
- ethValueAvailableInWei: liquidityInBigNumbers.ethValueAvailableInWei.toNumber(),
+ tokensAvailableInBaseUnits: liquidityInBigNumbers.tokensAvailableInBaseUnits,
+ ethValueAvailableInWei: liquidityInBigNumbers.ethValueAvailableInWei,
};
};