Permalink
Browse files

fix(http): all unhanded exceptions send 500 status code

Fixes #9758
  • Loading branch information...
mrclay committed Apr 21, 2016
1 parent 06eba73 commit 2f45c2ca96120352f0c0e3b8556e103924a3cc82
Showing with 1 addition and 0 deletions.
  1. +1 −0 engine/lib/elgglib.php
View
@@ -851,6 +851,7 @@ function _elgg_php_exception_handler($exception) {
} catch (Exception $e) {
$timestamp = time();
$message = $e->getMessage();
http_response_code(500);
echo "Fatal error in exception handler. Check log for Exception #$timestamp";
error_log("Exception #$timestamp : fatal error in exception handler : $message");
}

0 comments on commit 2f45c2c

Please sign in to comment.