Skip to content

Commit

Permalink
email validator
Browse files Browse the repository at this point in the history
  • Loading branch information
iesreza committed Mar 19, 2024
1 parent 5fc3c36 commit dc2dc21
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/validation/validators.go
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ func alphaNumericValidator(match []string, value *generic.Value) error {
return nil
}

var emailRegex = regexp.MustCompile(`(?i)^[a-z0-9_-]{2,}(\+\d+)?@[a-z0-9_-]{2,}\.[a-z0-9]{2,}$`)
var emailRegex = regexp.MustCompile(`(?i)^[a-z0-9_\-.]{2,}(\+\d+)?@[a-z0-9_-]{2,}\.[a-z0-9]{2,}$`)

func emailValidator(match []string, value *generic.Value) error {
var v = value.String()
Expand Down

0 comments on commit dc2dc21

Please sign in to comment.