Permalink
Browse files

ServerErrorAction always logs

  • Loading branch information...
1 parent aa9fcb9 commit a0f6b4f078252389eacf53dce1c5ca10951c76ac Evan Prodromou committed Aug 12, 2009
Showing with 5 additions and 0 deletions.
  1. +5 −0 lib/servererroraction.php
@@ -52,6 +52,7 @@
* @license http://www.fsf.org/licensing/licenses/agpl.html AGPLv3
* @link http://laconi.ca/
*/
+
class ServerErrorAction extends ErrorAction
{
function __construct($message='Error', $code=500)
@@ -66,6 +67,10 @@ function __construct($message='Error', $code=500)
505 => 'HTTP Version Not Supported');
$this->default = 500;
+
+ // Server errors must be logged.
+
+ common_log(LOG_ERR, "ServerErrorAction: $code $message");
}
// XXX: Should these error actions even be invokable via URI?

0 comments on commit a0f6b4f

Please sign in to comment.