Skip to content

Commit

Permalink
Added method getMapByParentPage
Browse files Browse the repository at this point in the history
  • Loading branch information
krazzer committed Jun 27, 2024
1 parent 4b69715 commit 94f35f4
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/Services/Pages/FullPageService.php
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,16 @@ public function getMapByParentKey(string $pageKey, int $limit = null): FullPageM
return new FullPageMap;
}

return $this->getMapByParentPage($parentPage, $limit);
}

/**
* @param Page $parentPage
* @param int|null $limit
* @return FullPageMap
*/
public function getMapByParentPage(Page $parentPage, int $limit = null): FullPageMap
{
$childPageMap = $this->pageService->getChildren($parentPage, $limit);

return $this->getByPageMap($childPageMap);
Expand Down

0 comments on commit 94f35f4

Please sign in to comment.