Named params
This commit is contained in:
parent
a08d5a5ef6
commit
d3cf892001
1 changed files with 8 additions and 1 deletions
|
@ -71,7 +71,14 @@ function createUser(string $hash, mixed $hashOptions, string $userId, ?string $e
|
|||
: ID::custom($userId);
|
||||
|
||||
if ($project->getAttribute('auths', [])['personalDataCheck'] ?? false) {
|
||||
$personalDataValidator = new PersonalData($userId, $email, $name, $phone, false, true);
|
||||
$personalDataValidator = new PersonalData(
|
||||
$userId,
|
||||
$email,
|
||||
$name,
|
||||
$phone,
|
||||
strict: false,
|
||||
allowEmpty: true
|
||||
);
|
||||
if (!$personalDataValidator->isValid($plaintextPassword)) {
|
||||
throw new Exception(Exception::USER_PASSWORD_PERSONAL_DATA);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue