Browse files

Limit what exceptionrenderer outputs.

The exception object should not be part of production errors.
  • Loading branch information...
1 parent b0d0e06 commit d9482fef25aa2ff77c369c811e0fc0057e4586a5 @markstory markstory committed Nov 17, 2011
Showing with 4 additions and 4 deletions.
  1. +4 −4 lib/Cake/Error/ExceptionRenderer.php
View
8 lib/Cake/Error/ExceptionRenderer.php
@@ -181,7 +181,7 @@ protected function _cakeError(CakeException $error) {
'url' => h($url),
'name' => $error->getMessage(),
'error' => $error,
- 'serialize' => array('code', 'error', 'name', 'url')
+ 'serialize' => array('code', 'url', 'name')
));
try {
$this->controller->set($error->getAttributes());
@@ -210,7 +210,7 @@ public function error400($error) {
'name' => $message,
'url' => h($url),
'error' => $error,
- 'serialize' => array('error', 'name', 'url')
+ 'serialize' => array('name', 'url')
));
$this->_outputMessage('error400');
}
@@ -233,7 +233,7 @@ public function error500($error) {
'name' => $message,
'message' => h($url),
'error' => $error,
- 'serialize' => array('error', 'name', 'url')
+ 'serialize' => array('name', 'message')
));
$this->_outputMessage('error500');
}
@@ -253,7 +253,7 @@ public function pdoError(PDOException $error) {
'url' => h($url),
'name' => $error->getMessage(),
'error' => $error,
- 'serialize' => array('code', 'error', 'name', 'url')
+ 'serialize' => array('code', 'url', 'name', 'error')
));
try {
$this->_outputMessage($this->template);

0 comments on commit d9482fe

Please sign in to comment.