private function configureSecurity(array $mergedConfig, ContainerBuilder $container)
    {
        foreach ($mergedConfig['commandbus'] as $commandBusConfig) {
            if (in_array('tactician.middleware.security', $commandBusConfig['middleware'])) {
                return $this->configureCommandSecurityVoter($mergedConfig, $container);
            }
        }
    }
private function configureSecurity(array $mergedConfig, ContainerBuilder $container)
    {
        foreach ($mergedConfig['commandbus'] as $commandBusConfig) {
            if (in_array('tactician.middleware.security', $commandBusConfig['middleware'])) {
                return $this->configureCommandSecurityVoter($mergedConfig, $container);
            }
        }
    }
private function configureSecurity ( array $ mergedConfig , ContainerBuilder $ container ) { foreach ( $ mergedConfig [ 'commandbus' ] as $ commandBusConfig ) { if ( in_array ( 'tactician.middleware.security' , $ commandBusConfig [ 'middleware' ] ) ) { return $ this -> configureCommandSecurityVoter ( $ mergedConfig , $ container ) ; } } }
Configure the security voter if the security middleware is loaded.

@param array $mergedConfig
@param ContainerBuilder $container
Configure the security voter if the security middleware is loaded .