mirror of
https://github.com/bisq-network/bisq.git
synced 2024-11-19 09:52:23 +01:00
Remove unnecessary static import
This commit is contained in:
parent
55d09a308b
commit
dadd22cc31
@ -17,15 +17,13 @@
|
||||
|
||||
package bisq.desktop.util.validation;
|
||||
|
||||
import bisq.core.btc.wallet.Restrictions;
|
||||
import bisq.core.locale.Res;
|
||||
import bisq.core.payment.PaymentAccount;
|
||||
import bisq.core.util.BSFormatter;
|
||||
|
||||
import javax.inject.Inject;
|
||||
|
||||
import static bisq.core.btc.wallet.Restrictions.getMaxBuyerSecurityDepositAsPercent;
|
||||
import static bisq.core.btc.wallet.Restrictions.getMinBuyerSecurityDepositAsPercent;
|
||||
|
||||
public class SecurityDepositValidator extends NumberValidator {
|
||||
|
||||
private final BSFormatter formatter;
|
||||
@ -61,7 +59,7 @@ public class SecurityDepositValidator extends NumberValidator {
|
||||
private ValidationResult validateIfNotTooLowPercentageValue(String input) {
|
||||
try {
|
||||
double percentage = formatter.parsePercentStringToDouble(input);
|
||||
double minPercentage = getMinBuyerSecurityDepositAsPercent(paymentAccount);
|
||||
double minPercentage = Restrictions.getMinBuyerSecurityDepositAsPercent(paymentAccount);
|
||||
if (percentage < minPercentage)
|
||||
return new ValidationResult(false,
|
||||
Res.get("validation.inputTooSmall", formatter.formatToPercentWithSymbol(minPercentage)));
|
||||
@ -75,7 +73,7 @@ public class SecurityDepositValidator extends NumberValidator {
|
||||
private ValidationResult validateIfNotTooHighPercentageValue(String input) {
|
||||
try {
|
||||
double percentage = formatter.parsePercentStringToDouble(input);
|
||||
double maxPercentage = getMaxBuyerSecurityDepositAsPercent(paymentAccount);
|
||||
double maxPercentage = Restrictions.getMaxBuyerSecurityDepositAsPercent(paymentAccount);
|
||||
if (percentage > maxPercentage)
|
||||
return new ValidationResult(false,
|
||||
Res.get("validation.inputTooLarge", formatter.formatToPercentWithSymbol(maxPercentage)));
|
||||
|
Loading…
Reference in New Issue
Block a user