Changed Stopwatch service to a factory.
This commit is contained in:
1 parent
054bf2e0df
commit
c93249875b
2 files changed
+8
-3
No files matched your search
@@ -8,7 +8,7 @@ use Rarst\Laps\Bootable_Provider_Interface;
|
||||
use Rarst\Laps\Laps;
|
||||
use Symfony\Component\Stopwatch\Stopwatch;
|
||||
|
||||
class Http_Events_Provider implements ServiceProviderInterface, Bootable_Provider_Interface {
|
||||
class Http_Events_Provider implements ServiceProviderInterface, Bootable_Provider_Interface, Events_Provider_Interface {
|
||||
|
||||
/** @var Stopwatch $stopwatch */
|
||||
protected $stopwatch;
|
||||
@@ -58,4 +58,9 @@ class Http_Events_Provider implements ServiceProviderInterface, Bootable_Provide
|
||||
|
||||
return $response;
|
||||
}
|
||||
|
||||
public function get_events() {
|
||||
|
||||
return $this->stopwatch->getSectionEvents( '__root__' );
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user