onFatalError($code, $error); } public function onFatalError($code, $error) { $this->onError($code, $error); // On error should exit but we're making doubly sure $this->response($code, $error); exit(); } protected function response($code, $response) { Http::response($code, $response); exit(); } abstract function onError($code, $error, $title=null, $logOnly=false); }