@@ -21,7 +21,7 @@ |
||
| 21 | 21 | */ |
| 22 | 22 | public function generate(): void |
| 23 | 23 | { |
| 24 | - $filteredPages = $this->pagesCollection->filter(function (Page $page) { |
|
| 24 | + $filteredPages = $this->pagesCollection->filter(function(Page $page) { |
|
| 25 | 25 | return null !== $page->getVariable('title'); |
| 26 | 26 | }); |
| 27 | 27 | |
@@ -34,7 +34,7 @@ |
||
| 34 | 34 | $paginationSections = $this->config->get('site.pagination.sections'); |
| 35 | 35 | |
| 36 | 36 | // filter pages: home and sections |
| 37 | - $filteredPages = $this->pagesCollection->filter(function (Page $page) { |
|
| 37 | + $filteredPages = $this->pagesCollection->filter(function(Page $page) { |
|
| 38 | 38 | return in_array($page->getType(), [Type::HOMEPAGE, Type::SECTION]); |
| 39 | 39 | }); |
| 40 | 40 | /* @var $page Page */ |
@@ -21,7 +21,7 @@ |
||
| 21 | 21 | */ |
| 22 | 22 | public function generate(): void |
| 23 | 23 | { |
| 24 | - $filteredPages = $this->pagesCollection->filter(function (Page $page) { |
|
| 24 | + $filteredPages = $this->pagesCollection->filter(function(Page $page) { |
|
| 25 | 25 | return null !== $page->getVariable('redirect') |
| 26 | 26 | && $page->getVariable('layout') != 'redirect'; |
| 27 | 27 | }); |
@@ -22,7 +22,7 @@ |
||
| 22 | 22 | */ |
| 23 | 23 | public function generate(): void |
| 24 | 24 | { |
| 25 | - $filteredPages = $this->pagesCollection->filter(function (Page $page) { |
|
| 25 | + $filteredPages = $this->pagesCollection->filter(function(Page $page) { |
|
| 26 | 26 | return null !== $page->getVariable('external'); |
| 27 | 27 | }); |
| 28 | 28 | |
@@ -21,7 +21,7 @@ |
||
| 21 | 21 | */ |
| 22 | 22 | public function generate(): void |
| 23 | 23 | { |
| 24 | - $subPages = $this->pagesCollection->filter(function (Page $page) { |
|
| 24 | + $subPages = $this->pagesCollection->filter(function(Page $page) { |
|
| 25 | 25 | return $page->getType() == TYPE::PAGE |
| 26 | 26 | && $page->getId() != 'index'; // exclude homepage |
| 27 | 27 | }); |
@@ -66,7 +66,7 @@ discard block |
||
| 66 | 66 | */ |
| 67 | 67 | protected function searchItem(string $id): ?array |
| 68 | 68 | { |
| 69 | - return array_filter($this->items, function ($item) use ($id) { |
|
| 69 | + return array_filter($this->items, function($item) use ($id) { |
|
| 70 | 70 | return $item->getId() == $id; |
| 71 | 71 | }); |
| 72 | 72 | } |
@@ -232,7 +232,7 @@ discard block |
||
| 232 | 232 | */ |
| 233 | 233 | public function usort(\Closure $callback = null): CollectionInterface |
| 234 | 234 | { |
| 235 | - $callback ? usort($this->items, $callback) : usort($this->items, function ($a, $b) { |
|
| 235 | + $callback ? usort($this->items, $callback) : usort($this->items, function($a, $b) { |
|
| 236 | 236 | if ($a == $b) { |
| 237 | 237 | return 0; |
| 238 | 238 | } |