function KernelEvent::isMainRequest

Checks if this is a main request.

Return value

bool True if the request is a main request

File

core/lib/Drupal/Core/Http/KernelEvent.php, line 84

Class

KernelEvent
Symfony 6 bridge.

Namespace

Drupal\Core\Http

Code

public function isMainRequest() {
    return HttpKernelInterface::MASTER_REQUEST === $this->requestType;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.