Skip to content

Commit

Permalink
email validator accepts domain both long and with unicode
Browse files Browse the repository at this point in the history
  • Loading branch information
Tezar committed Oct 4, 2024
1 parent e8800d2 commit 8aeb349
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion haxe/ui/validators/EmailValidator.hx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ class EmailValidator extends PatternValidator {
public function new() {
super();
invalidMessage = "Invalid email address";
pattern = ~/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/gm;
pattern = ~/^[^\-@\s:&!\/\\]+([\.-]?[^@\s:&!\/\\]+)*@[^\-@\s:&!\/\\\.]+([\.-]?[^@\s:&!\/\\\.]+)*(\.[^\-@\s:&!\/\\\.]{2,})+$/gm;
//pattern = new EReg("^\\w+([\\.-]?\\w+)*@\\w+([\\.-]?\\w+)*(\\.\\w{2,3})+$", "gm");
}
}

0 comments on commit 8aeb349

Please sign in to comment.