Skip to content

Commit f9be9af

Browse files
Merge branch '5.0' into 5.1
* 5.0: fix merge Require PHPUnit 9.3 on PHP 8 [Cache] fix catching auth errors Fix CS [FrameworkBundle] set default session.handler alias if handler_id is not provided Fix CS Readability update Fix checks for phpunit releases on Composer 2 (resolves #37601) [Serializer] Support multiple levels of discriminator mapping Use hexadecimal numerals instead of hexadecimals in strings to represent error codes. [SCA] Minor fixes on tests [WebProfilerBundle] modified url generation to use absolute urls [Mailer] Fix reply-to functionality in the SendgridApiTransport [Mime] Fix compat with HTTP requests ticket_36879 - Fix mandrill raw http request setting from email/name
2 parents c0f44c7 + 0fc0a93 commit f9be9af

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

DependencyInjection/FrameworkExtension.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -956,6 +956,7 @@ private function registerSessionConfiguration(array $config, ContainerBuilder $c
956956
// Set the handler class to be null
957957
$container->getDefinition('session.storage.native')->replaceArgument(1, null);
958958
$container->getDefinition('session.storage.php_bridge')->replaceArgument(0, null);
959+
$container->setAlias('session.handler', 'session.handler.native_file')->setPrivate(true);
959960
} else {
960961
$container->resolveEnvPlaceholders($config['handler_id'], null, $usedEnvs);
961962

Tests/DependencyInjection/FrameworkExtensionTest.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -503,6 +503,7 @@ public function testNullSessionHandler()
503503
$this->assertTrue($container->hasDefinition('session'), '->registerSessionConfiguration() loads session.xml');
504504
$this->assertNull($container->getDefinition('session.storage.native')->getArgument(1));
505505
$this->assertNull($container->getDefinition('session.storage.php_bridge')->getArgument(0));
506+
$this->assertSame('session.handler.native_file', (string) $container->getAlias('session.handler'));
506507

507508
$expected = ['session', 'initialized_session', 'logger'];
508509
$this->assertEquals($expected, array_keys($container->getDefinition('session_listener')->getArgument(0)->getValues()));

0 commit comments

Comments
 (0)