Merge remote-tracking branch 'origin/master' into wphan/health_check_fix

This commit is contained in:
wphan
2025-07-15 11:58:39 -07:00
3 changed files with 21 additions and 23 deletions

View File

@@ -891,11 +891,8 @@ export const mapToMarketOrderParams = async (
? PositionDirection.LONG
: PositionDirection.SHORT;
// Convert amount string to BN based on assetType
const amount =
params.assetType === 'base'
? stringToBN(params.amount).mul(BASE_PRECISION)
: stringToBN(params.amount).mul(QUOTE_PRECISION);
// Convert amount string to BN - amount is already in base or quote precision
const amount = stringToBN(params.amount);
// Convert additionalEndPriceBuffer string to BN with PRICE_PRECISION (1e6) if provided
const additionalEndPriceBuffer = params.additionalEndPriceBuffer