Skip to content

Commit 21ed097

Browse files
committed
minor #17529 [Stopwatch] add precision for stopwatch getEvent function (MrYamous)
This PR was merged into the 5.4 branch. Discussion ---------- [Stopwatch] add precision for stopwatch getEvent function This is not a big problem but I find this example confusing as getEvent() function from Stopwatch must have an event name as parameter Commits ------- 5cf6f9e add precision for stopwatch getEvent function
2 parents e3a159f + 5cf6f9e commit 21ed097

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

performance.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -278,7 +278,7 @@ information about the current event, even while it's still running. This
278278
object can be converted to a string for a quick summary::
279279

280280
// ...
281-
dump((string) $this->stopwatch->getEvent()); // dumps e.g. '4.50 MiB - 26 ms'
281+
dump((string) $this->stopwatch->getEvent('export-data')); // dumps e.g. '4.50 MiB - 26 ms'
282282

283283
You can also profile your template code with the :ref:`stopwatch Twig tag <reference-twig-tag-stopwatch>`:
284284

0 commit comments

Comments
 (0)