src/Sulu/Bundle/SecurityBundle/Controller/ResettingController.php
private function hasSystem(SuluUserInterface $user)
    {
        $system = $this->getSystem();
        foreach ($user->getRoleObjects() as $role) {
            if ($role->getSystem() === $system) {
                return true;
            }
        }

        return false;
    }
private function hasSystem(SuluUserInterface $user)
    {
        $system = $this->getSystem();
        foreach ($user->getRoleObjects() as $role) {
            if ($role->getSystem() === $system) {
                return true;
            }
        }

        return false;
    }
private function hasSystem ( SuluUserInterface $ user ) { $ system = $ this -> getSystem ( ) ; foreach ( $ user -> getRoleObjects ( ) as $ role ) { if ( $ role -> getSystem ( ) === $ system ) { return true ; } } return false ; }
Check if given user has sulu-system.

@param SuluUserInterface $user

@return bool
Check if given user has sulu - system .