/**
  * {@inheritdoc}
  */
 protected function logException(\Exception $exception, $message, $original = true)
 {
     if (!$exception instanceof BaseException) {
         parent::logException($exception, $message, $original);
         return;
     }
     if (null !== $this->logger) {
         if ($exception->getStatusCode() >= 500) {
             $this->logger->critical($message, array('exception' => $exception));
         } else {
             $this->logger->error($message, array('exception' => $exception));
         }
     }
 }