You are here

public function StopwatchEvent::ensureStopped in Devel 4.x

Same name and namespace in other branches
  1. 8.3 webprofiler/src/Stopwatch.php \Drupal\webprofiler\StopwatchEvent::ensureStopped()
  2. 8 webprofiler/src/Stopwatch.php \Drupal\webprofiler\StopwatchEvent::ensureStopped()
  3. 8.2 webprofiler/src/Stopwatch.php \Drupal\webprofiler\StopwatchEvent::ensureStopped()

Stops all non already stopped periods.

File

webprofiler/src/Stopwatch.php, line 445

Class

StopwatchEvent
Class StopwatchEvent.

Namespace

Drupal\webprofiler

Code

public function ensureStopped() {
  while (count($this->started)) {
    $this
      ->stop();
  }
}