keep name as well

This commit is contained in:
euromark 2014-01-03 16:33:02 +01:00
parent 85337a5d15
commit 71fb17e092

View file

@ -188,10 +188,11 @@ class ExceptionRenderer {
$this->controller->response->statusCode($code);
$this->controller->set(array(
'code' => $code,
'url' => h($url),
'mame' => h($error->getMessage()),
'message' => h($error->getMessage()),
'url' => h($url),
'error' => $error,
'_serialize' => array('code', 'url', 'message')
'_serialize' => array('code', 'name', 'message', 'url')
));
$this->controller->set($error->getAttributes());
$this->_outputMessage($this->template);
@ -211,10 +212,11 @@ class ExceptionRenderer {
$url = $this->controller->request->here();
$this->controller->response->statusCode($error->getCode());
$this->controller->set(array(
'url' => h($url),
'name' => h($message),
'message' => h($message),
'url' => h($url),
'error' => $error,
'_serialize' => array('url', 'message')
'_serialize' => array('name', 'message', 'url')
));
$this->_outputMessage('error400');
}
@ -234,10 +236,11 @@ class ExceptionRenderer {
$code = ($error->getCode() > 500 && $error->getCode() < 506) ? $error->getCode() : 500;
$this->controller->response->statusCode($code);
$this->controller->set(array(
'url' => h($url),
'name' => h($message),
'message' => h($message),
'url' => h($url),
'error' => $error,
'_serialize' => array('url', 'message')
'_serialize' => array('name', 'message', 'url')
));
$this->_outputMessage('error500');
}
@ -254,10 +257,11 @@ class ExceptionRenderer {
$this->controller->response->statusCode($code);
$this->controller->set(array(
'code' => $code,
'url' => h($url),
'name' => h($error->getMessage()),
'message' => h($error->getMessage()),
'url' => h($url),
'error' => $error,
'_serialize' => array('code', 'url', 'message', 'error')
'_serialize' => array('code', 'name', 'message', 'url', 'error')
));
$this->_outputMessage($this->template);
}