@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | /** @return $this */ |
20 | 20 | public function generate(): static |
21 | 21 | { |
22 | - Routes::getRoutes(DocumentationPage::class)->each(function (Route $route): void { |
|
22 | + Routes::getRoutes(DocumentationPage::class)->each(function(Route $route): void { |
|
23 | 23 | $this->items->put($route->getRouteKey(), NavItem::fromRoute($route)); |
24 | 24 | }); |
25 | 25 | |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | /** @return array<string> */ |
35 | 35 | public function getGroups(): array |
36 | 36 | { |
37 | - return $this->items->map(function (NavItem $item): string { |
|
37 | + return $this->items->map(function(NavItem $item): string { |
|
38 | 38 | return $item->getGroup(); |
39 | 39 | })->unique()->toArray(); |
40 | 40 | } |
@@ -42,7 +42,7 @@ discard block |
||
42 | 42 | /** @return Collection<\Hyde\Framework\Features\Navigation\NavItem> */ |
43 | 43 | public function getItemsInGroup(?string $group): Collection |
44 | 44 | { |
45 | - return $this->items->filter(function (NavItem $item) use ($group): bool { |
|
45 | + return $this->items->filter(function(NavItem $item) use ($group) : bool { |
|
46 | 46 | return ($item->getGroup() === $group) || ($item->getGroup() === Str::slug($group)); |
47 | 47 | })->sortBy('navigation.priority')->values(); |
48 | 48 | } |
@@ -43,7 +43,7 @@ |
||
43 | 43 | |
44 | 44 | protected static function validated(mixed $value, string $type, string $key): mixed |
45 | 45 | { |
46 | - if (! ("is_$type")($value)) { |
|
46 | + if (!("is_$type")($value)) { |
|
47 | 47 | throw new TypeError(sprintf('%s(): Config value %s must be of type %s, %s given', __METHOD__, $key, $type, gettype($value))); |
48 | 48 | } |
49 | 49 |