diff --git a/src/Service/Router.php b/src/Service/Router.php index eeb1424..8c631c0 100644 --- a/src/Service/Router.php +++ b/src/Service/Router.php @@ -107,7 +107,7 @@ class Router if ($route->getName() == $routeName) { if ($vars) { - // build route + // build route for dynamic routes $route = $route->getRoute(); // replace placeholder with current values foreach ($vars as $key => $value) { @@ -120,6 +120,15 @@ class Router } } // no 404, this is reached only if the code is wrong - die("Missing Route: $routeName"); + // TODO doesn't find the last route + /* + foreach (array_merge($this->dynamicRoutes, $this->staticRoutes) as $route) { + echo $route->getRoute() . '
'; + if ($routeName == $route->getRoute()) { + echo "equal"; + } + } + die("Missing Route: $routeName"); + */ } } \ No newline at end of file