Reset stopwatch.

This commit is contained in:
Alexander M. Turek 2017-09-13 22:59:37 +02:00
parent 30e3b6d27e
commit 7c3bdd9139
2 changed files with 6 additions and 2 deletions

View File

@ -753,7 +753,10 @@ class FrameworkExtension extends Extension
$container->getDefinition('debug.debug_handlers_listener')->setPrivate(true);
if (class_exists(Stopwatch::class)) {
$container->register('debug.stopwatch', Stopwatch::class)->addArgument(true)->setPrivate(true);
$container->register('debug.stopwatch', Stopwatch::class)
->addArgument(true)
->setPrivate(true)
->addTag('kernel.reset', array('method' => 'reset'));
$container->setAlias(Stopwatch::class, new Alias('debug.stopwatch', false));
}

View File

@ -46,7 +46,7 @@
"symfony/security-core": "~3.2|~4.0",
"symfony/security-csrf": "~2.8|~3.0|~4.0",
"symfony/serializer": "~3.3|~4.0",
"symfony/stopwatch": "~2.8|~3.0|~4.0",
"symfony/stopwatch": "~3.4|~4.0",
"symfony/translation": "~3.4|~4.0",
"symfony/templating": "~2.8|~3.0|~4.0",
"symfony/validator": "~3.4|~4.0",
@ -68,6 +68,7 @@
"symfony/form": "<3.4",
"symfony/property-info": "<3.3",
"symfony/serializer": "<3.3",
"symfony/stopwatch": "<3.4",
"symfony/translation": "<3.4",
"symfony/validator": "<3.4",
"symfony/workflow": "<3.3"