Merge pull request #105 from stephandesouza/master

Not always an Event Error need to throw an Exception.
This commit is contained in:
Denis
2013-10-22 13:13:17 -07:00
@@ -43,12 +43,15 @@ class ExceptionStrategy extends BaseExceptionStrategy {
case Application::ERROR_EXCEPTION:
default:
$response = $event->getResponse();
if (!$response || $response->getStatusCode() === 200) {
header('HTTP/1.0 500 Internal Server Error', true, 500);
$exception = $event->getParam('exception');
if($exception) {
$response = $event->getResponse();
if (!$response || $response->getStatusCode() === 200) {
header('HTTP/1.0 500 Internal Server Error', true, 500);
}
ob_clean();
$this->run->handleException($event->getParam('exception'));
}
ob_clean();
$this->run->handleException($event->getParam('exception'));
break;
}
}