[ticket/13230] Add missing globals and missing request object for path helper

PHPBB3-13230
This commit is contained in:
Joas Schilling 2014-10-27 14:54:17 +01:00
parent 51251293ab
commit 47759eb096

View file

@ -101,18 +101,21 @@ function phpbb_clean_path($path)
} }
else if (!$phpbb_path_helper) else if (!$phpbb_path_helper)
{ {
global $phpbb_root_path, $phpEx;
// The container is not yet loaded, use a new instance // The container is not yet loaded, use a new instance
if (!class_exists('\phpbb\path_helper')) if (!class_exists('\phpbb\path_helper'))
{ {
global $phpbb_root_path, $phpEx;
require($phpbb_root_path . 'phpbb/path_helper.' . $phpEx); require($phpbb_root_path . 'phpbb/path_helper.' . $phpEx);
} }
$request = new phpbb\request\request();
$phpbb_path_helper = new phpbb\path_helper( $phpbb_path_helper = new phpbb\path_helper(
new phpbb\symfony_request( new phpbb\symfony_request(
new phpbb\request\request() $request
), ),
new phpbb\filesystem(), new phpbb\filesystem(),
$request,
$phpbb_root_path, $phpbb_root_path,
$phpEx $phpEx
); );