/** * Generic callback, to catch uncaught exceptions when they bubble up to the top of the call chain. * * @ignore * @param Exception $exception */ public static function exception_handler($exception) { StaticPagesQueue::has_error(self::$current_url); $errno = E_USER_ERROR; $type = get_class($exception); $message = "Uncaught " . $type . ": " . $exception->getMessage(); $file = $exception->getFile(); $line = $exception->getLine(); $context = $exception->getTrace(); Debug::fatalHandler($errno, $message, $file, $line, $context); }