示例#1
0
 /**
  * Displays raw error without using any layout
  *
  * @param Exception $error
  * @internal
  */
 private function displayRawError(VegasException $error)
 {
     $this->di->get('response')->setContent($error->getCode() . ' ' . $error->getMessage());
 }
示例#2
0
 /**
  * Displays raw error without using any layout
  *
  * @param Exception $error
  * @internal
  */
 private function displayRawError(VegasException $error)
 {
     if (Constants::DEV_ENV === $this->di->get('environment')) {
         trigger_error($error->getCode() . ' ' . $error->getMessage() . ' ' . $error->getPrevious()->getTraceAsString(), E_USER_ERROR);
     } elseif (Constants::TEST_ENV === $this->di->get('environment')) {
         echo $error->getCode() . PHP_EOL . $error->getMessage() . PHP_EOL . $error->getPrevious()->getTraceAsString();
     }
 }