You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I use this library for validation registration form. But, when I try to check two fields - password and confirmPassword to equality with "equals" rule, it works incorrectly.
Firslty, I saw the same Notises and Warnings:
Notice: Undefined offset: 0 in /var/www/auth.lesson/vendor/vlucas/valitron/src/Valitron/Validator.php on line 159
Warning: vsprintf(): Too few arguments in /var/www/auth.lesson/vendor/vlucas/valitron/src/Valitron/Validator.php on line 714
Notice: Undefined offset: 0 in /var/www/auth.lesson/vendor/vlucas/valitron/src/Valitron/Validator.php on line 159
Warning: vsprintf(): Too few arguments in /var/www/auth.lesson/vendor/vlucas/valitron/src/Valitron/Validator.php on line 714
Than, I check result of validation and it's false for set of data:
password=11111111
confirmPassword=11111111
Other rules returs true. An error only with "euals"
This line tells our validator 'check that both the password and the confirm field have the same value as an undefined (null) field. That's of course not supposed to happen, which is why the error message doesn't get generated correctly as you can see by the vsprintf()-related errors.
Hello, I use this library for validation registration form. But, when I try to check two fields - password and confirmPassword to equality with "equals" rule, it works incorrectly.
Firslty, I saw the same Notises and Warnings:
Than, I check result of validation and it's false for set of data:
password=11111111
confirmPassword=11111111
Other rules returs true. An error only with "euals"
My full validation code
PASSWORD_MIN_LENGTH = 8 (so, there can't been problems with this)
The text was updated successfully, but these errors were encountered: