You are here

protected function EntityReferenceHelper::isUserOrConfigEntity in Entity Share 8.3

Helper function to check if an entity type id is a user or a config entity.

Parameters

string $entity_type_id: The entity type id.

Return value

bool TRUE if the entity type is user or a config entity. FALSE otherwise.

1 call to EntityReferenceHelper::isUserOrConfigEntity()
EntityReferenceHelper::relationshipHandleable in modules/entity_share_client/src/Service/EntityReferenceHelper.php
Check if a relationship is handleable.

File

modules/entity_share_client/src/Service/EntityReferenceHelper.php, line 72

Class

EntityReferenceHelper
Provides helper functions related to Entity reference fields.

Namespace

Drupal\entity_share_client\Service

Code

protected function isUserOrConfigEntity($entity_type_id) {
  if ($entity_type_id == 'user') {
    return TRUE;
  }
  elseif ($this->entityDefinitions[$entity_type_id]
    ->getGroup() == 'configuration') {
    return TRUE;
  }
  return FALSE;
}