]> git.mxchange.org Git - friendica.git/blobdiff - include/friendica_smarty.php
Merge pull request #4283 from MrPetovan/bug/2487-fix-autolink-regex
[friendica.git] / include / friendica_smarty.php
index f95bb69aaae2ef292f6cd79f209d55b09b82589a..1992a3716ee5e159fc995af1972af210f04c06f2 100644 (file)
@@ -19,10 +19,10 @@ class FriendicaSmarty extends Smarty
 
                // setTemplateDir can be set to an array, which Smarty will parse in order.
                // The order is thus very important here
-               $template_dirs = array('theme' => "view/theme/$theme/" . SMARTY3_TEMPLATE_FOLDER . "/");
+               $template_dirs = ['theme' => "view/theme/$theme/" . SMARTY3_TEMPLATE_FOLDER . "/"];
                if (x($a->theme_info, "extends"))
-                       $template_dirs = $template_dirs + array('extends' => "view/theme/" . $a->theme_info["extends"] . "/" . SMARTY3_TEMPLATE_FOLDER . "/");
-               $template_dirs = $template_dirs + array('base' => "view/" . SMARTY3_TEMPLATE_FOLDER . "/");
+                       $template_dirs = $template_dirs + ['extends' => "view/theme/" . $a->theme_info["extends"] . "/" . SMARTY3_TEMPLATE_FOLDER . "/"];
+               $template_dirs = $template_dirs + ['base' => "view/" . SMARTY3_TEMPLATE_FOLDER . "/"];
                $this->setTemplateDir($template_dirs);
 
                $this->setCompileDir('view/smarty3/compiled/');
@@ -70,10 +70,10 @@ class FriendicaSmartyEngine implements ITemplateEngine
                $r['$APP'] = get_app();
 
                // "middleware": inject variables into templates
-               $arr = array(
+               $arr = [
                        "template" => basename($s->filename),
                        "vars" => $r
-               );
+               ];
                call_hooks("template_vars", $arr);
                $r = $arr['vars'];