Remove all use of global variables as debug timers

This commit is contained in:
Kijin Sung 2025-08-20 00:34:57 +09:00
parent f91bd86fb1
commit 23190bd2f5
5 changed files with 17 additions and 24 deletions

View file

@ -183,7 +183,7 @@ class HTMLDisplayHandler
$pathInfo = pathinfo($layout_file);
$onlyLayoutFile = $pathInfo['filename'];
$GLOBALS['__layout_compile_elapsed__'] = microtime(true) - $start;
Rhymix\Framework\Debug::addTime('layout', microtime(true) - $start);
}
}
@ -297,7 +297,7 @@ class HTMLDisplayHandler
$output = preg_replace_callback('@<textarea[^>]*\sname="' . $keys . '".+</textarea>@isU', array(&$this, '_preserveTextAreaValue'), $output);
}
$GLOBALS['__trans_content_elapsed__'] = microtime(true) - $start;
Rhymix\Framework\Debug::addTime('trans_content', microtime(true) - $start);
// Remove unnecessary information
$output = preg_replace('/member\_\-([0-9]+)/s', 'member_0', $output);