浏览代码

Regex fixing

ahwelp 5 年之前
父节点
当前提交
2c1d01abea
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/Routes/Route.php

+ 1 - 1
src/Routes/Route.php

@@ -195,7 +195,7 @@ class Route {
             }
         }
         $this->_regex = ltrim($this->_regex, '\/');
-        $this->_regex = "/\/" . $this->_regex . "$/";
+        $this->_regex = "/^\/" . $this->_regex . "$/";
     }
 
     function createIndexes() {