From 5a83b07bf4bafae8c3613df340239300d808540a Mon Sep 17 00:00:00 2001 From: Maxime Steinhausser Date: Fri, 10 Jan 2020 21:25:30 +0100 Subject: [PATCH] [FrameworkBundle] Add missing entry about framework.router.context --- src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md | 1 + .../FrameworkBundle/DependencyInjection/Configuration.php | 2 +- .../FrameworkBundle/DependencyInjection/FrameworkExtension.php | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md b/src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md index 9a78822a33..32533ff70c 100644 --- a/src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md +++ b/src/Symfony/Bundle/FrameworkBundle/CHANGELOG.md @@ -4,6 +4,7 @@ CHANGELOG 5.1.0 ----- + * Added the `framework.router.context` configuration node to configure the `RequestContext` * Made `MicroKernelTrait::configureContainer()` compatible with `ContainerConfigurator` * Added a new `mailer.message_bus` option to configure or disable the message bus to use to send mails. * Added flex-compatible default implementations for `MicroKernelTrait::registerBundles()` and `getProjectDir()` diff --git a/src/Symfony/Bundle/FrameworkBundle/DependencyInjection/Configuration.php b/src/Symfony/Bundle/FrameworkBundle/DependencyInjection/Configuration.php index 8224e0a56b..0af78c2b47 100644 --- a/src/Symfony/Bundle/FrameworkBundle/DependencyInjection/Configuration.php +++ b/src/Symfony/Bundle/FrameworkBundle/DependencyInjection/Configuration.php @@ -483,7 +483,7 @@ class Configuration implements ConfigurationInterface ->end() ->booleanNode('utf8')->defaultFalse()->end() ->arrayNode('context') - ->info('router request context') + ->info('The request context used to generate URLs in a non-HTTP context') ->addDefaultsIfNotSet() ->children() ->scalarNode('host')->defaultValue('%router.request_context.host%')->end() diff --git a/src/Symfony/Bundle/FrameworkBundle/DependencyInjection/FrameworkExtension.php b/src/Symfony/Bundle/FrameworkBundle/DependencyInjection/FrameworkExtension.php index 45fd20a115..3b9e0cd903 100644 --- a/src/Symfony/Bundle/FrameworkBundle/DependencyInjection/FrameworkExtension.php +++ b/src/Symfony/Bundle/FrameworkBundle/DependencyInjection/FrameworkExtension.php @@ -854,7 +854,7 @@ class FrameworkExtension extends Extension $container->setParameter('request_listener.http_port', $config['http_port']); $container->setParameter('request_listener.https_port', $config['https_port']); - $requestContext = $container->findDefinition('router.request_context'); + $requestContext = $container->getDefinition('router.request_context'); $requestContext->replaceArgument(0, $config['context']['base_url']); $requestContext->replaceArgument(2, $config['context']['host']); $requestContext->replaceArgument(3, $config['context']['scheme']);