mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-25 19:38:53 +00:00
[ticket/12100] Re-order arguments in template environment constructor
PHPBB3-12100
This commit is contained in:
parent
75c54f7f5e
commit
d3ce584dc7
2 changed files with 8 additions and 7 deletions
|
@ -11,15 +11,15 @@ namespace phpbb\template\twig;
|
||||||
|
|
||||||
class environment extends \Twig_Environment
|
class environment extends \Twig_Environment
|
||||||
{
|
{
|
||||||
/** @var \phpbb\extension\manager */
|
|
||||||
protected $extension_manager;
|
|
||||||
|
|
||||||
/** @var \phpbb\config\config */
|
/** @var \phpbb\config\config */
|
||||||
protected $phpbb_config;
|
protected $phpbb_config;
|
||||||
|
|
||||||
/** @var \phpbb\path_helper */
|
/** @var \phpbb\path_helper */
|
||||||
protected $phpbb_path_helper;
|
protected $phpbb_path_helper;
|
||||||
|
|
||||||
|
/** @var \phpbb\extension\manager */
|
||||||
|
protected $extension_manager;
|
||||||
|
|
||||||
/** @var string */
|
/** @var string */
|
||||||
protected $phpbb_root_path;
|
protected $phpbb_root_path;
|
||||||
|
|
||||||
|
@ -33,18 +33,19 @@ class environment extends \Twig_Environment
|
||||||
* Constructor
|
* Constructor
|
||||||
*
|
*
|
||||||
* @param \phpbb\config\config $phpbb_config
|
* @param \phpbb\config\config $phpbb_config
|
||||||
* @param \phpbb\extension\manager
|
|
||||||
* @param \phpbb\path_helper
|
* @param \phpbb\path_helper
|
||||||
|
* @param \phpbb\extension\manager
|
||||||
* @param string $phpbb_root_path
|
* @param string $phpbb_root_path
|
||||||
* @param Twig_LoaderInterface $loader
|
* @param Twig_LoaderInterface $loader
|
||||||
* @param array $options Array of options to pass to Twig
|
* @param array $options Array of options to pass to Twig
|
||||||
*/
|
*/
|
||||||
public function __construct($phpbb_config, \phpbb\extension\manager $extension_manager = null, \phpbb\path_helper $path_helper, \Twig_LoaderInterface $loader = null, $options = array())
|
public function __construct($phpbb_config, \phpbb\path_helper $path_helper, \phpbb\extension\manager $extension_manager = null, \Twig_LoaderInterface $loader = null, $options = array())
|
||||||
{
|
{
|
||||||
$this->phpbb_config = $phpbb_config;
|
$this->phpbb_config = $phpbb_config;
|
||||||
$this->extension_manager = $extension_manager;
|
|
||||||
|
|
||||||
$this->phpbb_path_helper = $path_helper;
|
$this->phpbb_path_helper = $path_helper;
|
||||||
|
$this->extension_manager = $extension_manager;
|
||||||
|
|
||||||
$this->phpbb_root_path = $this->phpbb_path_helper->get_phpbb_root_path();
|
$this->phpbb_root_path = $this->phpbb_path_helper->get_phpbb_root_path();
|
||||||
$this->web_root_path = $this->phpbb_path_helper->get_web_root_path();
|
$this->web_root_path = $this->phpbb_path_helper->get_web_root_path();
|
||||||
|
|
||||||
|
|
|
@ -94,8 +94,8 @@ class twig extends \phpbb\template\base
|
||||||
|
|
||||||
$this->twig = new \phpbb\template\twig\environment(
|
$this->twig = new \phpbb\template\twig\environment(
|
||||||
$this->config,
|
$this->config,
|
||||||
$this->extension_manager,
|
|
||||||
$this->path_helper,
|
$this->path_helper,
|
||||||
|
$this->extension_manager,
|
||||||
$loader,
|
$loader,
|
||||||
array(
|
array(
|
||||||
'cache' => (defined('IN_INSTALL')) ? false : $this->cachepath,
|
'cache' => (defined('IN_INSTALL')) ? false : $this->cachepath,
|
||||||
|
|
Loading…
Add table
Reference in a new issue