Conditions | 1 |
Paths | 1 |
Total Lines | 7 |
Code Lines | 5 |
Lines | 0 |
Ratio | 0 % |
Tests | 5 |
CRAP Score | 1 |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
42 | 9 | public function callbackAfter(string $taskName): callable |
|
43 | { |
||
44 | return function () use ($taskName) { |
||
45 | 9 | $startTime = \array_pop($this->startTimeStack); |
|
46 | 9 | $duration = $this->clock->microtime() - $startTime; |
|
47 | 9 | $this->events->append( |
|
48 | 9 | new TimerEvent(TimerEvent::TYPE_END, $taskName, $this->clock->microtime(), $duration) |
|
49 | ); |
||
58 |