summaryrefslogtreecommitdiff
path: root/src/Router.php
diff options
context:
space:
mode:
Diffstat (limited to 'src/Router.php')
-rw-r--r--src/Router.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Router.php b/src/Router.php
index 4463150..1c5e087 100644
--- a/src/Router.php
+++ b/src/Router.php
@@ -126,7 +126,8 @@ class Router
$seg = $this->root();
while (($v = array_shift($pathSplit)) !== null) {
- $seg = $seg->child($v);
+ $typeMatch = PathSegmentType::matchRouteString($v);
+ $seg = $seg->child($typeMatch->value, $typeMatch->type);
}
$route = new Route($method, $handler);