You are here

public function FacetsSummary::calculateDependencies in Facets 8

Calculates dependencies and stores them in the dependency property.

Return value

$this

Overrides ConfigEntityBase::calculateDependencies

See also

\Drupal\Core\Config\Entity\ConfigDependencyManager

File

modules/facets_summary/src/Entity/FacetsSummary.php, line 283

Class

FacetsSummary
Defines the facet summary entity.

Namespace

Drupal\facets_summary\Entity

Code

public function calculateDependencies() {
  parent::calculateDependencies();
  if ($this
    ->getFacetSource() === NULL) {
    return $this;
  }
  $facet_source_dependencies = $this
    ->getFacetSource()
    ->calculateDependencies();
  if (!empty($facet_source_dependencies)) {
    $this
      ->addDependencies($facet_source_dependencies);
  }
  return $this;
}