From 89756761dc42a9d63ec8ad732a0bde7942dbc065 Mon Sep 17 00:00:00 2001 From: SilverFire - Dmitry Naumenko Date: Mon, 27 Mar 2017 17:26:02 +0300 Subject: [PATCH] Added passing handler to template --- src/handlers/TemplateHandler.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/handlers/TemplateHandler.php b/src/handlers/TemplateHandler.php index 3e6935c..e4d0c43 100644 --- a/src/handlers/TemplateHandler.php +++ b/src/handlers/TemplateHandler.php @@ -33,8 +33,9 @@ public function renderTemplate($data) public function prepareData($data) { return array_merge([ - 'config' => Yii::$app->config, - 'file' => $data->file, + 'config' => Yii::$app->config, + 'file' => $data->file, + 'handler' => $this ], parent::prepareData($data)); }