8000 merged branch mvrhov/cache_warmup_exception (PR #2445) · Kiruban2011/symfony@76148d0 · GitHub
[go: up one dir, main page]

Skip to content

Commit 76148d0

Browse files
committed
merged branch mvrhov/cache_warmup_exception (PR symfony#2445)
Commits ------- 6b872cf Check if cache_warmer service is available before doing the actual cache warmup Discussion ---------- fix cache warump exception when service is not available Bug fix: yes Feature addition: no Backwards compatibility break: no Symfony2 tests pass: yes Fixes the following tickets: N/A fixes [Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException] You have requested a non-existent service "cache_warmer". in console when FrameworkBundle is removed from kernel.
2 parents 1a43505 + 6b872cf commit 76148d0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Component/HttpKernel/Kernel.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -553,7 +553,7 @@ protected function initializeContainer()
553553
$this->container = new $class();
554554
$this->container->set('kernel', $this);
555555

556-
if (!$fresh) {
556+
if (!$fresh && $this->container->has('cache_warmer')) {
557557
$this->container->get('cache_warmer')->warmUp($this->container->getParameter('kernel.cache_dir'));
558558
}
559559
}

0 commit comments

Comments
 (0)
0