Skip to content

Commit

Permalink
修正路由分组合并检测
Browse files Browse the repository at this point in the history
  • Loading branch information
liu21st committed Jan 25, 2021
1 parent c2b477b commit db8fe22
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/think/route/RuleGroup.php
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ protected function checkMergeRuleRegex(Request $request, array &$rules, string $
}

try {
$result = preg_match('/^(?:' . implode('|', $regex) . ')/u', $url, $match);
$result = preg_match('~^(?:' . implode('|', $regex) . ')~u', $url, $match);
} catch (\Exception $e) {
throw new Exception('route pattern error');
}
Expand Down

0 comments on commit db8fe22

Please sign in to comment.