[HttpKernel] fixed the Kernel when the ClassLoader component is not available (closes #7406)

This commit is contained in:
Fabien Potencier 2013-04-12 14:45:07 +02:00
parent 9714cc2682
commit 972bde73ce
1 changed files with 3 additions and 1 deletions

View File

@ -101,7 +101,9 @@ abstract class Kernel implements KernelInterface, TerminableInterface
if ($this->debug) {
error_reporting(-1);
DebugClassLoader::enable();
if (class_exists('Symfony\Component\ClassLoader\DebugClassLoader')) {
DebugClassLoader::enable();
}
ErrorHandler::register($this->errorReportingLevel);
if ('cli' !== php_sapi_name()) {
ExceptionHandler::register();