From 1e69f5e7ac3414f307aac16842655a34a2f3c709 Mon Sep 17 00:00:00 2001 From: Robin Appelman Date: Fri, 3 Oct 2014 22:13:55 +0200 Subject: Log some basic events --- lib/private/diagnostics/event.php | 3 +++ 1 file changed, 3 insertions(+) (limited to 'lib/private/diagnostics') diff --git a/lib/private/diagnostics/event.php b/lib/private/diagnostics/event.php index 063c0c49dc2..af5d2ff8840 100644 --- a/lib/private/diagnostics/event.php +++ b/lib/private/diagnostics/event.php @@ -81,6 +81,9 @@ class Event implements IEvent { * @return float */ public function getDuration() { + if (!$this->end) { + $this->end = microtime(true); + } return $this->end - $this->start; } } -- cgit v1.2.3