email-validator.dart
email-validator.dart copied to clipboard
Invalid validation when user input email address in other languages like persian
First of all, thanks for creating such a wonderful package. I'm not sure if it's really an issue or not, and I just want to help this package get better. When testing the package with emails like [email protected] or [email protected], everything is fine. However, when giving the package inputs like:
ایمیل@جیمیل.کام
it returns true. In my case, I don't want to accept such emails in my program. I'm not sure if there is any email address like this or not, but I have never seen one. The above inputs are written in the Persian language, and the package only checks the pattern of an email and doesn't check the language of characters.
Try setting allowInternational to false (parameter to the validate function)