GuzzleMiddlewarePass.php

Namespace

Drupal\Core\DependencyInjection\Compiler

File

core/lib/Drupal/Core/DependencyInjection/Compiler/GuzzleMiddlewarePass.php

View source
<?php

namespace Drupal\Core\DependencyInjection\Compiler;

use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
use Symfony\Component\DependencyInjection\ContainerBuilder;
class GuzzleMiddlewarePass implements CompilerPassInterface {
    
    /**
     * {@inheritdoc}
     */
    public function process(ContainerBuilder $container) {
        $middleware_ids = array_keys($container->findTaggedServiceIds('http_client_middleware'));
        $container->getDefinition('http_handler_stack_configurator')
            ->addArgument($middleware_ids);
    }

}

Classes

Title Deprecated Summary
GuzzleMiddlewarePass

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.