mirror of
https://github.com/Karaka-Management/phpOMS.git
synced 2026-01-11 17:58:41 +00:00
Allow empty email
This commit is contained in:
parent
999b60999f
commit
244e2e8d86
|
|
@ -453,11 +453,11 @@ class Account implements ArrayableInterface, \JsonSerializable
|
|||
*/
|
||||
public function setEmail(string $email) : void
|
||||
{
|
||||
if (!Email::isValid($email)) {
|
||||
if ($email !== '' && !Email::isValid($email)) {
|
||||
throw new \InvalidArgumentException();
|
||||
}
|
||||
|
||||
$this->email = mb_strtolower($email);
|
||||
$this->email = \mb_strtolower($email);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user