revert 64def76b06
revert + helper: add function to compute and display time consuming between 2 endpoints.
This commit is contained in:
@@ -390,31 +390,6 @@ function formatTime($time, $format = '')
|
||||
return trim($time);
|
||||
}
|
||||
|
||||
/**
|
||||
* Display time consuming.
|
||||
*
|
||||
* @param string $tag
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function t($tag = '')
|
||||
{
|
||||
global $last;
|
||||
$time = microtime();
|
||||
|
||||
if($last)
|
||||
{
|
||||
list($lms, $ls) = explode(' ', $last);
|
||||
list($ms, $s) = explode(' ', $time);
|
||||
a("$tag: time consuming=" . ($s - $ls + round($ms - $lms, 3)) . 's');
|
||||
}
|
||||
else
|
||||
{
|
||||
a("$tag: current time={$time}");
|
||||
}
|
||||
$last = $time;
|
||||
}
|
||||
|
||||
/**
|
||||
* Fix for session error.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user