Skip to content

Commit

Permalink
Fix #10 unknown method findPublishedRegularWithoutGuestsByIds
Browse files Browse the repository at this point in the history
  • Loading branch information
ausi committed Oct 21, 2023
1 parent e6b31b4 commit 1a4c677
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/Module/MenuCustom.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ protected function compile()
$groups = $this->User->groups;
}

$objPages = PageModel::findPublishedRegularWithoutGuestsByIds(StringUtil::deserialize($this->pages, true));
$objPages = PageModel::findPublishedRegularByIds(StringUtil::deserialize($this->pages, true));

if ($objPages === null) {
return;
Expand All @@ -53,9 +53,9 @@ protected function compile()
$objTemplate->level = 'level_1';

while ($objPages->next()) {
$_groups = StringUtil::deserialize($arrPage['groups']);
$_groups = StringUtil::deserialize($objPages->groups);

if (!$arrPage['protected'] || System::getContainer()->get('contao.security.token_checker')->isPreviewMode() || (is_array($_groups) && count(array_intersect($_groups, $groups))) || $this->showProtected) {
if (!$objPages->protected || System::getContainer()->get('contao.security.token_checker')->isPreviewMode() || (is_array($_groups) && count(array_intersect($_groups, $groups))) || $this->showProtected) {
$arrPages[$objPages->id] = $this->getPageData($objPages);
if ($objPages->rsmm_enabled) {
$arrPages[$objPages->id]['subitems'] = $this->renderNavigation($objPages->id);
Expand Down

0 comments on commit 1a4c677

Please sign in to comment.