You are here

public function Permissions::scheduledUpdateTypesPermissions in Scheduled Updates 8

Returns an array of node type permissions.

Return value

array The node type permissions. @see \Drupal\user\PermissionHandlerInterface::getPermissions()

1 string reference to 'Permissions::scheduledUpdateTypesPermissions'
scheduled_updates.permissions.yml in ./scheduled_updates.permissions.yml
scheduled_updates.permissions.yml

File

src/Permissions.php, line 29
Contains \Drupal\scheduled_updates\Permissions.

Class

Permissions
Provides dynamic permissions for nodes of different types.

Namespace

Drupal\scheduled_updates

Code

public function scheduledUpdateTypesPermissions() {
  $perms = array();

  // Generate scheduled_update permissions for all scheduled updates types.
  foreach (ScheduledUpdateType::loadMultiple() as $type) {
    $perms += $this
      ->buildPermissions($type);
  }
  return $perms;
}