public function deleteUser($username)
    {
        /** @var UserInterface|EloquentUser $user */
        if ( ! ($user = $this->sentinel->findByCredentials(['email' => $username]))) {
            return false;
        }

        // The super admin may not be deleted.
        if ($user->isAdmin()) {
            return false;
        }

        return (bool) $user->delete();
    }
public function deleteUser($username)
    {
        /** @var UserInterface|EloquentUser $user */
        if ( ! ($user = $this->sentinel->findByCredentials(['email' => $username]))) {
            return false;
        }

        // The super admin may not be deleted.
        if ($user->isAdmin()) {
            return false;
        }

        return (bool) $user->delete();
    }
public function deleteUser ( $ username ) { /** @var UserInterface|EloquentUser $user */ if ( ! ( $ user = $ this -> sentinel -> findByCredentials ( [ 'email' => $ username ] ) ) ) { return false ; } // The super admin may not be deleted. if ( $ user -> isAdmin ( ) ) { return false ; } return ( bool ) $ user -> delete ( ) ; }
Removes a user from the CMS.

@param string $username
@return bool
Removes a user from the CMS .