From bc4b5c87a9e899968a0f7af115fa1844348ddaac Mon Sep 17 00:00:00 2001 From: Nathaniel Guse Date: Thu, 11 Jul 2013 10:45:23 -0500 Subject: [PATCH] [ticket/11388] Do not modify by reference PHPBB3-11388 --- phpBB/includes/style/style.php | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/phpBB/includes/style/style.php b/phpBB/includes/style/style.php index 06c16fdef4..7001d10f21 100644 --- a/phpBB/includes/style/style.php +++ b/phpBB/includes/style/style.php @@ -132,12 +132,13 @@ class phpbb_style $this->provider->set_styles($paths); $this->locator->set_paths($this->provider); - foreach ($paths as &$path) + $new_paths = array(); + foreach ($paths as $path) { - $path .= '/template/'; + $new_paths = $path . '/template/'; } - $this->template->set_style_names($this->names, $paths, ($style_directories === array('styles'))); + $this->template->set_style_names($this->names, $new_paths1, ($style_directories === array('styles'))); return true; } @@ -174,12 +175,13 @@ class phpbb_style $this->locator->set_template_path($template_path); } - foreach ($paths as &$path) + $new_paths = array(); + foreach ($paths as $path) { - $path .= '/' . (($template_path !== false) ? $template_path : 'template/'); + $new_paths = $path . '/' . (($template_path !== false) ? $template_path : 'template/'); } - $this->template->set_style_names($names, $paths); + $this->template->set_style_names($names, $new_paths); return true; }