diff options
Diffstat (limited to 'misc/render_template.php')
| -rw-r--r-- | misc/render_template.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/misc/render_template.php b/misc/render_template.php index 294fc16..1b64f0c 100644 --- a/misc/render_template.php +++ b/misc/render_template.php @@ -12,9 +12,10 @@ function render_template(string $templateName, array $args = []) { global $__spooky_magical_template_global_state; $__spooky_magical_template_global_state['slotParentArgs'] = $__spooky_magical_template_global_state['slotArgs'] ?? null; $__spooky_magical_template_global_state['slotArgs'] = $args; - foreach ($args as $key => $value) { - ${$key} = $value; + foreach ($args as $__template_key => $__template_value) { + ${$__template_key} = $__template_value; } + unset($__template_key, $__template_value); if (!function_exists('slot')) { function slot() { |
