From e5df80483433962aeb7f65175f98bdd6fe7635de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Julius=20H=C3=A4rtl?= Date: Thu, 25 Jan 2018 19:04:17 +0100 Subject: [PATCH] Expose parameters as variables to templates MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Julius Härtl --- lib/private/Template/Base.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/private/Template/Base.php b/lib/private/Template/Base.php index 18cf6324089..09be5ab7ddf 100644 --- a/lib/private/Template/Base.php +++ b/lib/private/Template/Base.php @@ -166,8 +166,11 @@ class Base { $l = $this->l10n; $theme = $this->theme; - if( !is_null($additionalParams)) { + if(!is_null($additionalParams)) { $_ = array_merge( $additionalParams, $this->vars ); + foreach ($_ as $var => $value) { + ${$var} = $value; + } } // Include