Back to ExceptionHandler class

Method handleException

public static void
handleException
(\Throwable $error)
Handles exceptions: logs errors and renders error page.
Parameters
  • \Exception|\Throwable $error An Exception or Throwable (PHP 7+) object for which to render the error page.
Returns
  • void
Since
  • 3.10.0

Method handleException - Source code

/**
 * Handles exceptions: logs errors and renders error page.
 *
 * @param   \Exception|\Throwable  $error  An Exception or Throwable (PHP 7+) object for which to render the error page.
 *
 * @return  void
 *
 * @since   3.10.0
 */
public static function handleException(\Throwable $error)
{
    static::logException($error);
    static::render($error);
}