public function configureCdnAdapter(ContainerBuilder $container, array $config): void
    {
        if ($container->hasDefinition('bkstg.core.cdn.private_do_spaces') && isset($config['cdn'])) {
            $container
                ->getDefinition('bkstg.core.cdn.private_do_spaces')
                ->replaceArgument(0, $config['cdn']['bucket'])
                ->replaceArgument(1, new Reference($config['cdn']['client']))
            ;
        } else {
            $container->removeDefinition('bkstg.core.cdn.private_do_spaces');
        }
    }
public function configureCdnAdapter(ContainerBuilder $container, array $config): void
    {
        if ($container->hasDefinition('bkstg.core.cdn.private_do_spaces') && isset($config['cdn'])) {
            $container
                ->getDefinition('bkstg.core.cdn.private_do_spaces')
                ->replaceArgument(0, $config['cdn']['bucket'])
                ->replaceArgument(1, new Reference($config['cdn']['client']))
            ;
        } else {
            $container->removeDefinition('bkstg.core.cdn.private_do_spaces');
        }
    }
public function configureCdnAdapter ( ContainerBuilder $ container , array $ config ) : void { if ( $ container -> hasDefinition ( 'bkstg.core.cdn.private_do_spaces' ) && isset ( $ config [ 'cdn' ] ) ) { $ container -> getDefinition ( 'bkstg.core.cdn.private_do_spaces' ) -> replaceArgument ( 0 , $ config [ 'cdn' ] [ 'bucket' ] ) -> replaceArgument ( 1 , new Reference ( $ config [ 'cdn' ] [ 'client' ] ) ) ; } else { $ container -> removeDefinition ( 'bkstg.core.cdn.private_do_spaces' ) ; } }
Configure the CDN adapter.

@param ContainerBuilder $container The container builder.
@param array            $config    The configuration.

@return void
Configure the CDN adapter .