You are here

public function XHProfEventSubscriber::onKernelTerminate in XHProf 8

Stops profiling and saves data.

File

src/EventSubscriber/XHProfEventSubscriber.php, line 129

Class

XHProfEventSubscriber
Provides handling of start/stop for profiler.

Namespace

Drupal\xhprof\EventSubscriber

Code

public function onKernelTerminate() {
  if ($this->profiler
    ->isEnabled()) {
    $this->profiler
      ->shutdown($this->xhprofRunId);
  }
}