diff --git a/src/PermissionManagerInterface.php b/src/PermissionManagerInterface.php index 7f474bc46..1a9f38dd7 100644 --- a/src/PermissionManagerInterface.php +++ b/src/PermissionManagerInterface.php @@ -44,9 +44,6 @@ public function getDefaultPermissions($group_entity_type_id, $group_bundle_id, a * PermissionEvent. The default permissions that ship with Organic Groups can * be found in OgEventSubscriber::provideDefaultOgPermissions(). * - * @see \Drupal\og\Event\PermissionEventInterface - * @see \Drupal\og\EventSubscriber\OgEventSubscriber::provideDefaultOgPermissions() - * * @param string $group_entity_type_id * The entity type ID of the group for which to return permissions. * @param string $group_bundle_id @@ -57,6 +54,9 @@ public function getDefaultPermissions($group_entity_type_id, $group_bundle_id, a * * @return \Drupal\og\GroupPermission[] * An array of permissions that are enabled by default for the given role. + * + * @see \Drupal\og\Event\PermissionEventInterface + * @see \Drupal\og\EventSubscriber\OgEventSubscriber::provideDefaultOgPermissions() */ public function getDefaultGroupPermissions($group_entity_type_id, $group_bundle_id, $role_name = NULL); @@ -71,10 +71,6 @@ public function getDefaultGroupPermissions($group_entity_type_id, $group_bundle_ * content operation permissions that ship with Organic Groups can be found in * OgEventSubscriber. * - * @see \Drupal\og\Event\PermissionEventInterface - * @see \Drupal\og\EventSubscriber\OgEventSubscriber::provideDefaultNodePermissions() - * @see \Drupal\og\EventSubscriber\OgEventSubscriber::getDefaultEntityOperationPermissions() - * * @param string $group_entity_type_id * The entity type ID of the group for which to return permissions. * @param string $group_bundle_id @@ -88,6 +84,10 @@ public function getDefaultGroupPermissions($group_entity_type_id, $group_bundle_ * * @return \Drupal\og\GroupContentOperationPermission[] * The array of permissions. + * + * @see \Drupal\og\Event\PermissionEventInterface + * @see \Drupal\og\EventSubscriber\OgEventSubscriber::provideDefaultNodePermissions() + * @see \Drupal\og\EventSubscriber\OgEventSubscriber::getDefaultEntityOperationPermissions() */ public function getDefaultEntityOperationPermissions($group_entity_type_id, $group_bundle_id, array $group_content_bundle_ids, $role_name = NULL); diff --git a/tests/src/Kernel/Access/GroupLevelAccessTest.php b/tests/src/Kernel/Access/GroupLevelAccessTest.php index a4f4d9201..220a9adef 100644 --- a/tests/src/Kernel/Access/GroupLevelAccessTest.php +++ b/tests/src/Kernel/Access/GroupLevelAccessTest.php @@ -329,7 +329,8 @@ public function testGroupEntityOperationPermissions(string $user, array $access_ // Also check that the access result is correctly communicated to // hook_entity_access(). - $hook_result = \Drupal::moduleHandler()->invokeAll( 'entity_access', [$this->group, $operation, $user]); + $arguments = [$this->group, $operation, $user]; + $hook_result = \Drupal::moduleHandler()->invokeAll('entity_access', $arguments); // The hook returns an array of access results, add them all up. if (empty($hook_result)) { @@ -351,6 +352,7 @@ public function testGroupEntityOperationPermissions(string $user, array $access_ * Returns test users with permissions to perform group entity operations. * * @return \Drupal\user\UserInterface[] + * The test users. */ protected function setupGroupEntityOperationPermissions(): array { // Return the users from the generic test setup. @@ -444,4 +446,5 @@ public function groupEntityOperationPermissionsTestProvider(): array { ], ]; } + }