public function WorkspaceRepository::getDescendantsAndSelf in Drupal 10
Same name and namespace in other branches
- 8 core/modules/workspaces/src/WorkspaceRepository.php \Drupal\workspaces\WorkspaceRepository::getDescendantsAndSelf()
- 9 core/modules/workspaces/src/WorkspaceRepository.php \Drupal\workspaces\WorkspaceRepository::getDescendantsAndSelf()
File
- core/
modules/ workspaces/ src/ WorkspaceRepository.php, line 139
Class
- WorkspaceRepository
- Provides the default workspace tree lookup operations.
Namespace
Drupal\workspacesCode
public function getDescendantsAndSelf($workspace_id) {
return array_merge([
$workspace_id,
], $this
->loadTree()[$workspace_id]['descendants']);
}