Skip to content

Commit

Permalink
fix: outer options are not merged with inner options
Browse files Browse the repository at this point in the history
  • Loading branch information
kenjis committed Sep 26, 2023
1 parent 61ac2c5 commit 46dca50
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion system/Router/RouteCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -771,7 +771,10 @@ public function group(string $name, ...$params)
$callback = array_pop($params);

if ($params && is_array($params[0])) {
$this->currentOptions = array_shift($params);
$this->currentOptions = array_merge(
$this->currentOptions ?? [],
array_shift($params)
);
}

if (is_callable($callback)) {
Expand Down

0 comments on commit 46dca50

Please sign in to comment.