Skip to content

Commit 13d4358

Browse files
committed
email validation
1 parent 866d521 commit 13d4358

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/validation/validators.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -873,7 +873,7 @@ func alphaNumericValidator(match []string, value *generic.Value) error {
873873
return nil
874874
}
875875

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

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

0 commit comments

Comments
 (0)