diff --git a/revert_default_perm.module b/revert_default_perm.module index 24ee1c94599af702acb6fdf953c65e3512e7b8c9..2af9fd4ea619268fca7943bae31d45efc90dd8d9 100644 --- a/revert_default_perm.module +++ b/revert_default_perm.module @@ -21,9 +21,7 @@ function revert_default_perm_form_alter(&$form, &$form_state, $form_id) { // Check if the entity has a canonical route. $route_provider = \Drupal::service('router.route_provider'); $canonical = $route_provider->getRoutesByNames(["entity.{$bundle_of}.canonical"]); - // If there is no canonical route, ignore. - // Also, we exclude block_content entities, becuase it has a canonical link, but it is used to edit - // the entity instead of it being a normal landing page. + // Check if the entity has a canonical route and does not block content. if (empty($canonical) || $bundle_of == "block_content") { return; }