mirror of
https://github.com/GitJournal/GitJournal.git
synced 2025-06-29 02:07:39 +08:00
Email Regexp: Allow dashes
This commit is contained in:
@ -103,7 +103,8 @@ class SettingsListState extends State<SettingsList> {
|
||||
}
|
||||
|
||||
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) {
|
||||
return 'Please enter a valid email';
|
||||
}
|
||||
|
Reference in New Issue
Block a user