You are here

public function ProfilerSubscriber::onKernelException in Devel 8.2

Same name and namespace in other branches
  1. 8.3 webprofiler/src/EventSubscriber/ProfilerSubscriber.php \Drupal\webprofiler\EventSubscriber\ProfilerSubscriber::onKernelException()
  2. 8 webprofiler/src/EventSubscriber/ProfilerSubscriber.php \Drupal\webprofiler\EventSubscriber\ProfilerSubscriber::onKernelException()
  3. 4.x webprofiler/src/EventSubscriber/ProfilerSubscriber.php \Drupal\webprofiler\EventSubscriber\ProfilerSubscriber::onKernelException()

Handles the onKernelException event.

File

webprofiler/src/EventSubscriber/ProfilerSubscriber.php, line 54

Class

ProfilerSubscriber

Namespace

Drupal\webprofiler\EventSubscriber

Code

public function onKernelException(GetResponseForExceptionEvent $event) {
  if ($this->onlyMasterRequests && !$event
    ->isMasterRequest()) {
    return;
  }
  $this->exception = $event
    ->getException();
}