forked from leftypol/leftypol
More $config['debug'] improvements to time-related stuff
This commit is contained in:
parent
8921eb9c1a
commit
343803afb9
5 changed files with 47 additions and 20 deletions
6
mod.php
6
mod.php
|
@ -8,6 +8,9 @@ require 'inc/functions.php';
|
|||
require 'inc/mod/pages.php';
|
||||
require 'inc/mod/auth.php';
|
||||
|
||||
if ($config['debug'])
|
||||
$parse_start_time = microtime(true);
|
||||
|
||||
// Fix for magic quotes
|
||||
if (get_magic_quotes_gpc()) {
|
||||
function strip_array($var) {
|
||||
|
@ -156,8 +159,9 @@ foreach ($pages as $uri => $handler) {
|
|||
$debug['mod_page'] = array(
|
||||
'req' => $query,
|
||||
'match' => $uri,
|
||||
'handler' => $handler
|
||||
'handler' => $handler,
|
||||
);
|
||||
$debug['time']['parse_mod_req'] = '~' . round((microtime(true) - $parse_start_time) * 1000, 2) . 'ms';
|
||||
}
|
||||
|
||||
if (is_string($handler)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue