Layton/App.php
private function getMiddleWareFromRoute(Route $route)
    {
        if (!$route->group) {
            return $route->middleWare;
        }
        $groupMiddleWare = $this->getMiddleWareFromGroup($route->group);
        return \array_merge($groupMiddleWare, $route->middleWare);
    }
private function getMiddleWareFromRoute(Route $route)
    {
        if (!$route->group) {
            return $route->middleWare;
        }
        $groupMiddleWare = $this->getMiddleWareFromGroup($route->group);
        return \array_merge($groupMiddleWare, $route->middleWare);
    }
private function getMiddleWareFromRoute ( Route $ route ) { if ( ! $ route -> group ) { return $ route -> middleWare ; } $ groupMiddleWare = $ this -> getMiddleWareFromGroup ( $ route -> group ) ; return \ array_merge ( $ groupMiddleWare , $ route -> middleWare ) ; }
Get middle ware from Route

@param Route $route

@return array
Get middle ware from Route