Password regex accept _ and -
This commit is contained in:
parent
274c285aa8
commit
724b29f944
@ -118,7 +118,7 @@ export default function Login() {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
const passwordRegex = new RegExp(/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)[A-Za-z\d@$!%*?&]{8,}$/);
|
const passwordRegex = new RegExp(/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)[A-Za-z\d@$!%*?&_\\-]{8,}$/);
|
||||||
if (!passwordRegex.test(values["password"])) {
|
if (!passwordRegex.test(values["password"])) {
|
||||||
setValidationErrors([
|
setValidationErrors([
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user