Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[EPAD8-2651] Resolving bug where some Web Area content was not displaying the breadcrumbs. #1558

Merged
merged 1 commit into from
Oct 31, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -203,9 +203,12 @@ public function applies(RouteMatchInterface $route_match) {
}

$group = $group_content->getGroup();
$menus = group_content_menu_get_menus_per_group($group);
$menu = reset($menus);
$menu_id = GroupContentMenuInterface::MENU_PREFIX . $menu->id();
$gc_menus = group_content_menu_get_menus_per_group($group);
$gc_menu = reset($gc_menus);
// The object loaded is a group content object. The actual menu is what's returned from the getEntity() call.
// For unknown reasons (presumably an artifact of the migration) the loaded $gc_menu object's ID is different than the menu ID which does work for a majority of web areas.
// This change should always work as we're always going to get the correct entity ID now.
$menu_id = GroupContentMenuInterface::MENU_PREFIX . $gc_menu->getEntity()->id();

if ($menu_id) {
$this->menuTrail = [];
Expand Down