File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed
Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -55,16 +55,15 @@ public static function create(ContainerInterface $container) {
5555 * List of available admin routes for the current group.
5656 */
5757 public function overview (RouteMatchInterface $ route_match ) {
58+ $ entity_type_id = $ route_match ->getRouteObject ()->getOption ('_og_entiy_type_id ' );
5859 /** @var \Drupal\Core\Entity\EntityInterface $group */
59- $ group = $ route_match ->getParameter ('group ' );
60- if (!is_object ($ group )) {
61- return ;
62- }
60+ $ group = $ route_match ->getParameter ($ entity_type_id ?: 'group ' );
61+
6362 // Get list from routes.
6463 $ content = [];
6564
6665 $ route_name = "og_admin.members " ;
67- $ parameters = ['entity_type_id ' => $ group ->getEntityTypeId (), 'group ' => $ group ->id ()];
66+ $ parameters = ['entity_type_id ' => $ group ->getEntityTypeId () ?: $ entity_type_id , 'group ' => $ group ->id ()];
6867
6968 // We don't use Url::fromRoute() here for the access check, as it will
7069 // prevent us from unit testing this method.
You can’t perform that action at this time.
0 commit comments