UserRules::validEmail()
Validates an email address
UserRules::validEmail(Kirby\Cms\User $user, string $email, bool $strict = false): void
Parameters
| Name | Type | Default |
|---|---|---|
| $userrequired | Kirby\Cms\User |
no default value |
| $emailrequired | string |
no default value |
| $strict | bool |
false
|
Exceptions
| Type | Description |
|---|---|
Kirby\Exception\DuplicateException |
If the email address already exists |
Kirby\Exception\InvalidArgumentException |
If the email address is invalid |