Skip to content

Commit

Permalink
Merge pull request #20 from Adduc/patch-7
Browse files Browse the repository at this point in the history
Don't add base path when route is '*' , fixes #18 . Thank you @adduc !
  • Loading branch information
dannyvankooten committed Sep 12, 2013
2 parents b8f9944 + 7508642 commit f8a92a9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion AltoRouter.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,9 @@ public function setBasePath($basePath) {
*/
public function map($method, $route, $target, $name = null) {

$route = $this->basePath . $route;
if($route != '*') {
$route = $this->basePath . $route;
}

$this->routes[] = array($method, $route, $target, $name);

Expand Down

0 comments on commit f8a92a9

Please sign in to comment.