public function createService(ServiceLocatorInterface $serviceLocator)
    {
        $identityRoleProvider = new IdentityRoleProvider(
            $serviceLocator->get('UserRbac\UserRoleLinkerMapper'),
            $serviceLocator->get('UserRbac\ModuleOptions')
        );
        if ($serviceLocator->get('zfcuser_auth_service')->hasIdentity()) {
            $identityRoleProvider->setDefaultIdentity(
                $serviceLocator->get('zfcuser_auth_service')->getIdentity()
            );
        }

        return $identityRoleProvider;
    }
public function createService(ServiceLocatorInterface $serviceLocator)
    {
        $identityRoleProvider = new IdentityRoleProvider(
            $serviceLocator->get('UserRbac\UserRoleLinkerMapper'),
            $serviceLocator->get('UserRbac\ModuleOptions')
        );
        if ($serviceLocator->get('zfcuser_auth_service')->hasIdentity()) {
            $identityRoleProvider->setDefaultIdentity(
                $serviceLocator->get('zfcuser_auth_service')->getIdentity()
            );
        }

        return $identityRoleProvider;
    }
public function createService ( ServiceLocatorInterface $ serviceLocator ) { $ identityRoleProvider = new IdentityRoleProvider ( $ serviceLocator -> get ( 'UserRbac\UserRoleLinkerMapper' ) , $ serviceLocator -> get ( 'UserRbac\ModuleOptions' ) ) ; if ( $ serviceLocator -> get ( 'zfcuser_auth_service' ) -> hasIdentity ( ) ) { $ identityRoleProvider -> setDefaultIdentity ( $ serviceLocator -> get ( 'zfcuser_auth_service' ) -> getIdentity ( ) ) ; } return $ identityRoleProvider ; }
Gets identity role provider

@param  ServiceLocatorInterface $serviceLocator
@return IdentityRoleProvider
Gets identity role provider