diff --git a/app/Schedule/Scheduler.php b/app/Schedule/Scheduler.php index 801f4763e..3e08fc7cd 100644 --- a/app/Schedule/Scheduler.php +++ b/app/Schedule/Scheduler.php @@ -2,7 +2,7 @@ namespace Gazelle\Schedule; -use \Gazelle\Util\{Irc, Time}; +use \Gazelle\Util\Irc; class Scheduler { protected $db; @@ -287,7 +287,7 @@ class Scheduler { FROM periodic_task pt INNER JOIN periodic_task_history pth USING (periodic_task_id) WHERE pth.launch_time <= ? AND pth.launch_time + INTERVAL pth.duration_ms / 1000 SECOND >= ? - ', Time::sqlTime($end), Time::sqlTime($start) + ', $end, $start ); return $this->db->to_array('periodic_task_id', MYSQLI_ASSOC); diff --git a/classes/debug.class.php b/classes/debug.class.php index 18103433f..a5551a399 100644 --- a/classes/debug.class.php +++ b/classes/debug.class.php @@ -1,4 +1,6 @@ Perf['Memory usage'] = (($Ram>>10) / 1024).' MB'; - $this->Perf['Page process time'] = number_format($Micro / 1000, 3).' s'; - $this->Perf['CPU time'] = number_format($this->get_cpu_time() / 1000000, 3).' s'; - if (isset($Reason[0])) { $this->log_var($CacheStatus, 'Cache server status'); $this->analysis(implode(', ', $Reason)); @@ -221,12 +219,12 @@ class DEBUG { $Perf = [ 'Memory usage' => Format::get_size(memory_get_usage(true)), 'Page process time' => number_format($PageTime, 3).' s', - 'Script start' => $ScriptStartTime, - 'Script end' => microtime(true) ]; if ($CPUTime) { $Perf['CPU time'] = number_format($CPUTime / 1000000, 3).' s'; } + $Perf['Script start'] = Time::sqlTime($ScriptStartTime); + $Perf['Script end'] = Time::sqlTime(microtime(true)); return $Perf; } return $this->Perf; @@ -626,17 +624,16 @@ class DEBUG {