diff options
author | Andreas Fischer <bantu@phpbb.com> | 2011-09-19 16:58:25 +0200 |
---|---|---|
committer | Andreas Fischer <bantu@phpbb.com> | 2011-09-19 16:58:25 +0200 |
commit | 12530a763b436c3d01d2668999dc343a95926389 (patch) | |
tree | d4a682e1909669ee4e58c9ef6cacf754ece88f7a /phpBB/includes/functions.php | |
parent | 9c0f75fd65e51212f5ef61e901420ea2f14a7a38 (diff) | |
download | forums-12530a763b436c3d01d2668999dc343a95926389.tar forums-12530a763b436c3d01d2668999dc343a95926389.tar.gz forums-12530a763b436c3d01d2668999dc343a95926389.tar.bz2 forums-12530a763b436c3d01d2668999dc343a95926389.tar.xz forums-12530a763b436c3d01d2668999dc343a95926389.zip |
[ticket/10370] Use unset() on the first backtrace instead of checking in loop.
PHPBB3-10370
Diffstat (limited to 'phpBB/includes/functions.php')
-rw-r--r-- | phpBB/includes/functions.php | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/phpBB/includes/functions.php b/phpBB/includes/functions.php index c2c8e489df..b203dcbea3 100644 --- a/phpBB/includes/functions.php +++ b/phpBB/includes/functions.php @@ -3394,14 +3394,11 @@ function get_backtrace() $output = '<div style="font-family: monospace;">'; $backtrace = debug_backtrace(); - foreach ($backtrace as $number => $trace) - { - // We skip the first one, because it only shows this file/function - if ($number == 0) - { - continue; - } + // We skip the first one, because it only shows this file/function + unset($backtrace[0]); + foreach ($backtrace as $trace) + { // Strip the current directory from path $trace['file'] = (empty($trace['file'])) ? '' : phpbb_filter_root_path($trace['file']); $args = array(); |