Skip to content
This repository was archived by the owner on Jan 29, 2020. It is now read-only.

Commit b58e9f1

Browse files
author
nikolay
committed
injectTemplateListener - injectTemplate update to match the unit test
1 parent eee1a35 commit b58e9f1

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/View/Http/InjectTemplateListener.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,9 @@ public function injectTemplate(MvcEvent $e)
6161
}
6262

6363
$routeMatch = $e->getRouteMatch();
64-
$preferRouteMatchController = $routeMatch->getParam('prefer_route_match_controller', false);
65-
$this->setPreferRouteMatchController($preferRouteMatchController);
64+
if($preferRouteMatchController = $routeMatch->getParam('prefer_route_match_controller', false)){
65+
$this->setPreferRouteMatchController($preferRouteMatchController);
66+
}
6667

6768
$controller = $e->getTarget();
6869
if (is_object($controller)) {

0 commit comments

Comments
 (0)