Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. ErrorController.php

function ErrorController::__invoke

File

vendor/symfony/http-kernel/Controller/ErrorController.php, line 35

Class

ErrorController
Renders error or exception pages from a given FlattenException.

Namespace

Symfony\Component\HttpKernel\Controller

Code

public function __invoke(\Throwable $exception) : Response {
    $exception = $this->errorRenderer
        ->render($exception);
    return new Response($exception->getAsString(), $exception->getStatusCode(), $exception->getHeaders());
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal