diff --git a/src/CurrentRoute/View/Helper/CurrentRoute.php b/src/CurrentRoute/View/Helper/CurrentRoute.php index c863136..8aec5c8 100644 --- a/src/CurrentRoute/View/Helper/CurrentRoute.php +++ b/src/CurrentRoute/View/Helper/CurrentRoute.php @@ -22,8 +22,8 @@ class CurrentRoute extends AbstractHelper */ public function __construct($controller, $action, $route, $module) { - $controller = explode('\\', strtolower($controller)); - $module = explode('\\', strtolower($module)); + $controller = explode('\\', strtolower($controller ?? '')); + $module = explode('\\', strtolower($module ?? '')); if($module[0] === '' && count($controller) === 3) { $module[0] = $controller[0];