Neos\Neos\Controller\Module\Administration\UsersController::deleteAction PHP Метод

deleteAction() публичный Метод

Delete the given user
public deleteAction ( User $user ) : void
$user Neos\Neos\Domain\Model\User
Результат void
    public function deleteAction(User $user)
    {
        if ($user === $this->currentUser) {
            $this->addFlashMessage('You can not delete the currently logged in user', 'Current user can\'t be deleted', Message::SEVERITY_WARNING, array(), 1412374546);
            $this->redirect('index');
        }
        $this->userService->deleteUser($user);
        $this->addFlashMessage('The user "%s" has been deleted.', 'User deleted', Message::SEVERITY_NOTICE, array(htmlspecialchars($user->getName()->getFullName())), 1412374546);
        $this->redirect('index');
    }