`getGlobal` to `getGlobals()`
This commit is contained in:
parent
b86e856fe7
commit
93311f1857
|
@ -78,14 +78,15 @@ final class templater extends controller implements array_access
|
||||||
* Render the HTML-document
|
* Render the HTML-document
|
||||||
*
|
*
|
||||||
* @param string $$file Related path to a HTML-document
|
* @param string $$file Related path to a HTML-document
|
||||||
* @param ?array $$variables Registry of variables to push into registry of global variables
|
* @param array $$variables Registry of variables to push into registry of global variables
|
||||||
*
|
*
|
||||||
* @return ?string HTML-document
|
* @return ?string HTML-document
|
||||||
*/
|
*/
|
||||||
public function render(string $$file, ?array $$variables = null): ?string
|
public function render(string $$file, array $$variables = []): ?string
|
||||||
{
|
{
|
||||||
// Generation and exit (success)
|
// Generation and exit (success)
|
||||||
return $$this->twig->render('themes' . DIRECTORY_SEPARATOR . $$this->twig->getGlobal('theme') . DIRECTORY_SEPARATOR . $$file, $$variables + $$this->variables);
|
return $$this->twig->render('themes' . DIRECTORY_SEPARATOR . $$this->twig->getGlobals()['theme'] . DIRECTORY_SEPARATOR . $$file, $$variables + $$this->variables);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue