mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-10 13:28:55 +00:00
[feature/twig] Remove the get_rootref and get_tpldata functions prev added
These are not really necessary PHPBB3-11598
This commit is contained in:
parent
9749405129
commit
8d3fd1fcdd
2 changed files with 3 additions and 24 deletions
|
@ -82,26 +82,6 @@ class phpbb_template_context
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Get (non-referenced) rootref
|
|
||||||
*
|
|
||||||
* @return array
|
|
||||||
*/
|
|
||||||
public function get_rootref()
|
|
||||||
{
|
|
||||||
return $this->rootref;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Get (non-referenced) tpldata
|
|
||||||
*
|
|
||||||
* @return array
|
|
||||||
*/
|
|
||||||
public function get_tpldata()
|
|
||||||
{
|
|
||||||
return $this->tpldata;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a reference to template data array.
|
* Returns a reference to template data array.
|
||||||
*
|
*
|
||||||
|
|
|
@ -432,12 +432,11 @@ class phpbb_template_twig implements phpbb_template
|
||||||
*/
|
*/
|
||||||
public function get_template_vars()
|
public function get_template_vars()
|
||||||
{
|
{
|
||||||
$vars = array();
|
$context_vars = $this->context->get_data_ref();
|
||||||
|
|
||||||
$vars = array_merge(
|
$vars = array_merge(
|
||||||
$vars,
|
$context_vars['.'][0], // To get normal vars
|
||||||
$this->context->get_rootref(),
|
$context_vars, // To get loops
|
||||||
$this->context->get_tpldata(),
|
|
||||||
array(
|
array(
|
||||||
'definition' => new phpbb_template_twig_definition(),
|
'definition' => new phpbb_template_twig_definition(),
|
||||||
'user' => $this->user,
|
'user' => $this->user,
|
||||||
|
|
Loading…
Add table
Reference in a new issue