mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-09 11:44:10 +09:00
Fix #2313 inconsistent email validation rules
This commit is contained in:
parent
61a0cf38c3
commit
848a45cabe
3 changed files with 13 additions and 3 deletions
|
|
@ -405,7 +405,7 @@ class VariableBase
|
|||
{
|
||||
case 'email':
|
||||
case 'email_address':
|
||||
if (!preg_match('/^[\w-]+((?:\.|\+|\~)[\w-]+)*@[\w-]+(\.[\w-]+)+$/', $value))
|
||||
if (!\Mail::isVaildMailAddress($value))
|
||||
{
|
||||
throw new \Rhymix\Framework\Exceptions\QueryError('Variable ' . $this->var . ' for column ' . $column . ' must contain a valid e-mail address');
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue