$auth->impersonate()
Become any existing user or disable the current user
Parameters
Name | Type | Default | Description |
---|---|---|---|
$who | string |null |
null |
User ID or email address,null to use the actual user again,'kirby' for a virtual admin user or'nobody' to disable the actual user |
Return type
Kirby\Cms\User
|null
Exceptions
Type | Description |
---|---|
Kirby\Exception\NotFoundException |
if the given user cannot be found |