You are here

public function DomainPathHelper::domainPathsIsEnabled in Domain Path 8

Check if domain paths is enabled for a given entity.

Parameters

\Drupal\Core\Entity\EntityInterface $entity: The entity object.

Return value

boolean Return TRUE or FALSE.

2 calls to DomainPathHelper::domainPathsIsEnabled()
DomainPathHelper::alterEntityForm in src/DomainPathHelper.php
The domain paths form element for the entity form.
DomainPathHelper::deleteEntityDomainPaths in src/DomainPathHelper.php
Helper function for deleting domain paths from an entity.

File

src/DomainPathHelper.php, line 460

Class

DomainPathHelper

Namespace

Drupal\domain_path

Code

public function domainPathsIsEnabled(EntityInterface $entity) {
  return in_array($entity
    ->getEntityTypeId(), $this
    ->getConfiguredEntityTypes());
}