Skip to content

Commit

Permalink
Fix broken use()/prefix() of routers
Browse files Browse the repository at this point in the history
  • Loading branch information
bwoebi committed Apr 9, 2016
1 parent 198f285 commit 6ba57a5
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions lib/Router.php
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,6 @@ public function use($action) {
foreach ($action->routes as $route) {
$route[2] = array_merge($this->actions, $route[2]);
$this->routes[] = $route;
$this->actions = array_merge($this->actions, $action->actions);
}
} else {
$this->actions[] = $action;
Expand All @@ -186,7 +185,6 @@ public function prefix(string $prefix) {
$route[1] = "/$prefix$route[1]";
}

$this->routes[] = ["*", "/$prefix/{path:.*}", $this->actions];
$this->actions = [];
}

Expand Down

0 comments on commit 6ba57a5

Please sign in to comment.