Rounded memory value, saw a screenshot with it blowing up (hadn't seen on my systems).
This commit is contained in:
1 parent
950031bbaf
commit
d724958dec
1 file changed
+1
-1
@@ -43,7 +43,7 @@ class Stopwatch_Record implements Record_Interface {
|
|||||||
public function get_description(): string {
|
public function get_description(): string {
|
||||||
|
|
||||||
$duration = round( $this->stopwatch_event->getDuration() );
|
$duration = round( $this->stopwatch_event->getDuration() );
|
||||||
$memory = $this->stopwatch_event->getMemory() / 1024 / 1024;
|
$memory = round( $this->stopwatch_event->getMemory() / 1024 / 1024, 2 );
|
||||||
$description = '' !== $this->description ? "<hr />{$this->description}" : '';
|
$description = '' !== $this->description ? "<hr />{$this->description}" : '';
|
||||||
|
|
||||||
return "{$this->name} – {$duration} ms – {$memory} MB{$description}";
|
return "{$this->name} – {$duration} ms – {$memory} MB{$description}";
|
||||||
|
|||||||
Reference in new issue
Block a user