Business Propfile set up email validation fix

This commit is contained in:
2024-11-08 16:21:20 +02:00
parent bd42827199
commit 4799ec2336

View File

@@ -200,7 +200,7 @@ class _ProfileBusinessAddState extends State<ProfileBusinessAdd> {
bool validEmail() {
String text = emailController.text;
var regex = RegExp(r'^[a-zA-Z0-9]+@[a-zA-Z.-]+\.[a-zA-Z]{2,}$');
var regex = RegExp(r'^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$');
return regex.hasMatch(text);
}