From bee0bc581ed6a3e22b9e841f812e6b1eb768b138 Mon Sep 17 00:00:00 2001 From: hrach Date: Sat, 22 Aug 2015 14:31:26 +0200 Subject: [PATCH] TemplateControlTrait: fixed template initialization in beforeRender --- src/Controls/Fragments/TemplateControlTrait.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Controls/Fragments/TemplateControlTrait.php b/src/Controls/Fragments/TemplateControlTrait.php index a08b9c0..d458862 100644 --- a/src/Controls/Fragments/TemplateControlTrait.php +++ b/src/Controls/Fragments/TemplateControlTrait.php @@ -84,8 +84,9 @@ public function render() */ public function toString() { + $template = $this->getTemplate(); $this->beforeRender(); - return (string) $this->getTemplate(); + return (string) $template; }