Skip to content

Commit

Permalink
Add back price format
Browse files Browse the repository at this point in the history
  • Loading branch information
moo-onthelawn committed Apr 26, 2024
1 parent be09d61 commit 40fdc3f
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,7 @@ internal class TriggerOrdersInputValidator(
mapOf(
"TRIGGER_PRICE_LIMIT" to mapOf(
"value" to liquidationPrice,
"format" to "price",
"tickSize" to tickSize,
),
),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,7 @@ internal class TradeBracketOrdersValidator(
mapOf(
"TRIGGER_PRICE_LIMIT" to mapOf(
"value" to liquidationPrice,
"format" to "price",
"tickSize" to tickSize,
),
),
Expand All @@ -185,6 +186,7 @@ internal class TradeBracketOrdersValidator(
mapOf(
"TRIGGER_PRICE_LIMIT" to mapOf(
"value" to liquidationPrice,
"format" to "price",
"tickSize" to tickSize,
),
),
Expand Down Expand Up @@ -326,6 +328,7 @@ internal class TradeBracketOrdersValidator(
mapOf(
"TRIGGER_PRICE_LIMIT" to mapOf(
"value" to liquidationPrice,
"format" to "price",
"tickSize" to tickSize,
),
),
Expand All @@ -345,6 +348,7 @@ internal class TradeBracketOrdersValidator(
mapOf(
"TRIGGER_PRICE_LIMIT" to mapOf(
"value" to liquidationPrice,
"format" to "price",
"tickSize" to tickSize,
),
),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,13 @@ internal class TradeTriggerPriceValidator(
val action = "APP.TRADE.MODIFY_TRIGGER_PRICE"
// Localizations uses TRIGGER_PRICE_LIMIT as paramater name
val params =
mapOf("TRIGGER_PRICE_LIMIT" to mapOf("value" to triggerLiquidation, "tickSize" to tickSize))
mapOf(
"TRIGGER_PRICE_LIMIT" to mapOf(
"value" to triggerLiquidation,
"format" to "price",
"tickSize" to tickSize,
),
)
return when (triggerToLiquidation) {
RelativeToPrice.ABOVE -> error(
"ERROR",
Expand Down

0 comments on commit 40fdc3f

Please sign in to comment.