public function getMenu($pageUid, array $excludePages = [], $includeNotInMenu = false, $includeMenuSeparator = false, $disableGroupAccessCheck = false)
{
$pageRepository = $this->getPageRepository();
$pageConstraints = $this->getPageConstraints($excludePages, $includeNotInMenu, $includeMenuSeparator);
$cacheKey = md5($pageUid . $pageConstraints . (int) $disableGroupAccessCheck);
if (false === isset(static::$cachedMenus[$cacheKey])) {
if (true === (bool) $disableGroupAccessCheck) {
$pageRepository->where_groupAccess = '';
}
static::$cachedMenus[$cacheKey] = $pageRepository->getMenu($pageUid, '*', 'sorting', $pageConstraints);
}
return static::$cachedMenus[$cacheKey];
}