-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update trigger price validation #6109
Conversation
@@ -72,7 +72,8 @@ public static MonetaryValidator getPriceValidator(boolean isFiatCurrency) { | |||
} | |||
|
|||
public static InputValidator.ValidationResult isTriggerPriceValid(String triggerPriceAsString, | |||
Price price, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd rather use the MarketPrice object exposing the currencyCode property instead of adding another parameter. WDYT?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea - fixed
@xyzmaker123 Did you also check the trigger price actual execution code? I'd surprised, if only changing the UI validation will do the work as expected. |
@ripcurlx I roughly reviewed it. I think changing validation criteria is enough - we basically add more flexibility to user to set trigger price possible values, but execution logic doesn't change. |
True - just looked at the code myself. There doesn't seem to be any special handling that matches the one of the validation before. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK - tested UI validation on Regtest. Behavior for positiv difference to market does not change only for negative difference (against your advantage).
Fixes #5979