mirror of
https://github.com/GitJournal/GitJournal.git
synced 2025-06-29 10:17:16 +08:00
Email Regexp: Allow dashes
This commit is contained in:
@ -103,7 +103,8 @@ class SettingsListState extends State<SettingsList> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
bool emailValid =
|
bool emailValid =
|
||||||
RegExp(r"^[a-zA-Z0-9.]+@[a-zA-Z0-9]+\.[a-zA-Z]+").hasMatch(value);
|
RegExp(r"^[a-zA-Z0-9.\-]+@[a-zA-Z0-9\-]+\.[a-zA-Z\-]+")
|
||||||
|
.hasMatch(value);
|
||||||
if (!emailValid) {
|
if (!emailValid) {
|
||||||
return 'Please enter a valid email';
|
return 'Please enter a valid email';
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user