mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-24 10:23:17 +00:00
Port PHRAS-2877
Port of PHRAS-2877 User manipulator did not allow to set a null email Temporary Null email is used by saml plugin while creating a user.
This commit is contained in:
@@ -368,7 +368,7 @@ class UserManipulator implements ManipulatorInterface
|
|||||||
throw new InvalidArgumentException(sprintf('Email %s is not legal.', $email));
|
throw new InvalidArgumentException(sprintf('Email %s is not legal.', $email));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (null !== $this->repository->findByEmail($email)) {
|
if (($email !== null) && (null !== $this->repository->findByEmail($email))) {
|
||||||
throw new RuntimeException(sprintf('User with email %s already exists.', $email));
|
throw new RuntimeException(sprintf('User with email %s already exists.', $email));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user