aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes
diff options
context:
space:
mode:
authorTristan Darricau <github@nicofuma.fr>2014-06-13 14:53:30 +0200
committerTristan Darricau <github@nicofuma.fr>2014-06-13 14:53:30 +0200
commitdc4132a49458b4a0ce8e8a80cf329e902108b575 (patch)
tree00543ae3f608c8ab65d70eb437836ff890072074 /phpBB/includes
parentf7f65fe6c2d77682214d3aca0fcfcd185566475b (diff)
downloadforums-dc4132a49458b4a0ce8e8a80cf329e902108b575.tar
forums-dc4132a49458b4a0ce8e8a80cf329e902108b575.tar.gz
forums-dc4132a49458b4a0ce8e8a80cf329e902108b575.tar.bz2
forums-dc4132a49458b4a0ce8e8a80cf329e902108b575.tar.xz
forums-dc4132a49458b4a0ce8e8a80cf329e902108b575.zip
[ticket/12687] Wrap $GLOBALS['starttime'] in a if
PHPBB3-12687
Diffstat (limited to 'phpBB/includes')
-rw-r--r--phpBB/includes/functions.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/phpBB/includes/functions.php b/phpBB/includes/functions.php
index e554ee8cee..7f36062c20 100644
--- a/phpBB/includes/functions.php
+++ b/phpBB/includes/functions.php
@@ -5060,9 +5060,12 @@ function phpbb_generate_debug_output(phpbb\db\driver\driver_interface $db, \phpb
// Output page creation time
if (defined('PHPBB_DISPLAY_LOAD_TIME'))
{
- $totaltime = microtime(true) - $GLOBALS['starttime'];
+ if (isset($GLOBALS['starttime']))
+ {
+ $totaltime = microtime(true) - $GLOBALS['starttime'];
+ $debug_info[] = sprintf('Time : %.3fs', $totaltime);
+ }
- $debug_info[] = sprintf('Time : %.3fs', $totaltime);
$debug_info[] = $db->sql_num_queries() . ' Queries';
if (function_exists('memory_get_peak_usage'))