Merge branch '4.3' into 4.4
* 4.3: cs fix cs fix [HttpKernel] Remove outdated docblock comment Fix handling for session parameters
This commit is contained in:
commit
a2ef397ea3
@ -12,7 +12,6 @@
|
||||
namespace Symfony\Bridge\ProxyManager\Tests\LazyProxy\PhpDumper;
|
||||
|
||||
use PHPUnit\Framework\TestCase;
|
||||
use ProxyManager\Version;
|
||||
use Symfony\Bridge\ProxyManager\LazyProxy\PhpDumper\ProxyDumper;
|
||||
use Symfony\Component\DependencyInjection\Definition;
|
||||
use Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\DumperInterface;
|
||||
|
@ -174,7 +174,7 @@ abstract class Descriptor implements DescriptorInterface
|
||||
/**
|
||||
* Describes a callable.
|
||||
*
|
||||
* @param callable $callable
|
||||
* @param mixed $callable
|
||||
*/
|
||||
abstract protected function describeCallable($callable, array $options = []);
|
||||
|
||||
|
@ -898,7 +898,7 @@ class FrameworkExtension extends Extension
|
||||
// session storage
|
||||
$container->setAlias('session.storage', $config['storage_id'])->setPrivate(true);
|
||||
$options = ['cache_limiter' => '0'];
|
||||
foreach (['name', 'cookie_lifetime', 'cookie_path', 'cookie_domain', 'cookie_secure', 'cookie_httponly', 'cookie_samesite', 'use_cookies', 'gc_maxlifetime', 'gc_probability', 'gc_divisor'] as $key) {
|
||||
foreach (['name', 'cookie_lifetime', 'cookie_path', 'cookie_domain', 'cookie_secure', 'cookie_httponly', 'cookie_samesite', 'use_cookies', 'gc_maxlifetime', 'gc_probability', 'gc_divisor', 'sid_length', 'sid_bits_per_character'] as $key) {
|
||||
if (isset($config[$key])) {
|
||||
$options[$key] = $config[$key];
|
||||
}
|
||||
|
@ -37,6 +37,8 @@ $container->loadFromExtension('framework', [
|
||||
'gc_maxlifetime' => 90000,
|
||||
'gc_divisor' => 108,
|
||||
'gc_probability' => 1,
|
||||
'sid_length' => 22,
|
||||
'sid_bits_per_character' => 4,
|
||||
'save_path' => '/path/to/sessions',
|
||||
],
|
||||
'assets' => [
|
||||
|
@ -15,7 +15,7 @@
|
||||
<framework:ssi enabled="true" />
|
||||
<framework:profiler only-exceptions="true" enabled="false" />
|
||||
<framework:router resource="%kernel.project_dir%/config/routing.xml" type="xml" />
|
||||
<framework:session gc-maxlifetime="90000" gc-probability="1" gc-divisor="108" storage-id="session.storage.native" handler-id="session.handler.native_file" name="_SYMFONY" cookie-lifetime="86400" cookie-path="/" cookie-domain="example.com" cookie-secure="true" cookie-httponly="false" use-cookies="true" save-path="/path/to/sessions" />
|
||||
<framework:session gc-maxlifetime="90000" gc-probability="1" gc-divisor="108" storage-id="session.storage.native" handler-id="session.handler.native_file" name="_SYMFONY" cookie-lifetime="86400" cookie-path="/" cookie-domain="example.com" cookie-secure="true" cookie-httponly="false" use-cookies="true" save-path="/path/to/sessions" sid-length="22" sid-bits-per-character="4" />
|
||||
<framework:request>
|
||||
<framework:format name="csv">
|
||||
<framework:mime-type>text/csv</framework:mime-type>
|
||||
|
@ -29,6 +29,8 @@ framework:
|
||||
gc_probability: 1
|
||||
gc_divisor: 108
|
||||
gc_maxlifetime: 90000
|
||||
sid_length: 22
|
||||
sid_bits_per_character: 4
|
||||
save_path: /path/to/sessions
|
||||
assets:
|
||||
version: v1
|
||||
|
@ -532,6 +532,8 @@ abstract class FrameworkExtensionTest extends TestCase
|
||||
$this->assertEquals(108, $options['gc_divisor']);
|
||||
$this->assertEquals(1, $options['gc_probability']);
|
||||
$this->assertEquals(90000, $options['gc_maxlifetime']);
|
||||
$this->assertEquals(22, $options['sid_length']);
|
||||
$this->assertEquals(4, $options['sid_bits_per_character']);
|
||||
|
||||
$this->assertEquals('/path/to/sessions', $container->getParameter('session.save_path'));
|
||||
}
|
||||
|
@ -114,6 +114,9 @@ class Translator implements TranslatorInterface
|
||||
return ($prefix ?: '').$this->nodeToXPath($selector);
|
||||
}
|
||||
|
||||
/**
|
||||
* @return $this
|
||||
*/
|
||||
public function registerExtension(Extension\ExtensionInterface $extension): self
|
||||
{
|
||||
$this->extensions[$extension->getName()] = $extension;
|
||||
@ -139,6 +142,9 @@ class Translator implements TranslatorInterface
|
||||
return $this->extensions[$name];
|
||||
}
|
||||
|
||||
/**
|
||||
* @return $this
|
||||
*/
|
||||
public function registerParserShortcut(ParserInterface $shortcut): self
|
||||
{
|
||||
$this->shortcutParsers[] = $shortcut;
|
||||
|
@ -200,9 +200,7 @@ class YamlDumper extends Dumper
|
||||
/**
|
||||
* Dumps callable to YAML format.
|
||||
*
|
||||
* @param callable $callable
|
||||
*
|
||||
* @return callable
|
||||
* @param mixed $callable
|
||||
*/
|
||||
private function dumpCallable($callable)
|
||||
{
|
||||
|
@ -18,8 +18,7 @@ use Symfony\Component\DependencyInjection\ContainerBuilder;
|
||||
use Symfony\Component\DependencyInjection\Extension\ExtensionInterface;
|
||||
|
||||
/**
|
||||
* An implementation of BundleInterface that adds a few conventions
|
||||
* for DependencyInjection extensions and Console commands.
|
||||
* An implementation of BundleInterface that adds a few conventions for DependencyInjection extensions.
|
||||
*
|
||||
* @author Fabien Potencier <fabien@symfony.com>
|
||||
*/
|
||||
|
Reference in New Issue
Block a user