瀏覽代碼

Fixed status code check

Jordi Boggiano 14 年之前
父節點
當前提交
fd08f187c8
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/Symfony/Component/HttpKernel/Debug/ExceptionListener.php

+ 1 - 1
src/Symfony/Component/HttpKernel/Debug/ExceptionListener.php

@@ -77,7 +77,7 @@ class ExceptionListener
         } catch (\Exception $e) {
         } catch (\Exception $e) {
             $message = sprintf('Exception thrown when handling an exception (%s: %s)', get_class($e), $e->getMessage());
             $message = sprintf('Exception thrown when handling an exception (%s: %s)', get_class($e), $e->getMessage());
             if (null !== $this->logger) {
             if (null !== $this->logger) {
-                if ($exception instanceof HttpExceptionInterface && $exception->getStatusCode() > 500) {
+                if ($exception instanceof HttpExceptionInterface && $exception->getStatusCode() >= 500) {
                     $this->logger->crit($message);
                     $this->logger->crit($message);
                 } else {
                 } else {
                     $this->logger->err($message);
                     $this->logger->err($message);