20250714#1
This commit is contained in:
1 parent
3b1d74f0a3
commit
d4142655a5
1 file changed
+1
-1
+1
-1
@@ -33,7 +33,7 @@ class Router implements RouterInterface {
|
||||
// заменяем алиасы на регвыражения
|
||||
$realPattern = str_replace(["<@any>", "<@num>", "<@path>"], [".*", "[0-9]+", "[^/]+"], $realPattern);
|
||||
// при наличии слеша в конце правила url должно строго ему соответствовать
|
||||
$end = (str_ends_with($realPattern, "/")) ? "$" : "";
|
||||
$end = (str_ends_with($realPattern, "/")) ? "$" : "/?$";
|
||||
|
||||
// меняем запись на паттерн
|
||||
$this->rules[$rulesKey] = $rulesNode;
|
||||
|
||||
Reference in new issue
Block a user