mirror of
https://github.com/boldsuck/haveno.git
synced 2024-12-22 20:19:21 +00:00
increase max question length for InteracETransfer to 160 characters #969
This commit is contained in:
parent
cf1fabd0bb
commit
0919d92ce4
2 changed files with 2 additions and 2 deletions
|
@ -13,7 +13,7 @@ public class InteracETransferQuestionValidator extends InputValidator {
|
||||||
public InteracETransferQuestionValidator(LengthValidator lengthValidator, RegexValidator regexValidator) {
|
public InteracETransferQuestionValidator(LengthValidator lengthValidator, RegexValidator regexValidator) {
|
||||||
|
|
||||||
lengthValidator.setMinLength(1);
|
lengthValidator.setMinLength(1);
|
||||||
lengthValidator.setMaxLength(40);
|
lengthValidator.setMaxLength(160);
|
||||||
this.lengthValidator = lengthValidator;
|
this.lengthValidator = lengthValidator;
|
||||||
|
|
||||||
regexValidator.setPattern("[A-Za-z0-9\\-\\_\\'\\,\\.\\? ]+");
|
regexValidator.setPattern("[A-Za-z0-9\\-\\_\\'\\,\\.\\? ]+");
|
||||||
|
|
|
@ -53,7 +53,7 @@ public class InteracETransferQuestionValidatorTest {
|
||||||
|
|
||||||
assertFalse(validator.validate(null).isValid); // null
|
assertFalse(validator.validate(null).isValid); // null
|
||||||
assertFalse(validator.validate("").isValid); // empty
|
assertFalse(validator.validate("").isValid); // empty
|
||||||
assertFalse(validator.validate("abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ").isValid); // too long
|
assertFalse(validator.validate("abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ").isValid); // too long
|
||||||
assertFalse(validator.validate("abc !@#").isValid); // invalid characters
|
assertFalse(validator.validate("abc !@#").isValid); // invalid characters
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue