You are here

public function Microsite::getHome in Entity Reference Hierarchy 3.x

Same name and namespace in other branches
  1. 8.2 modules/entity_hierarchy_microsite/src/Entity/Microsite.php \Drupal\entity_hierarchy_microsite\Entity\Microsite::getHome()

Gets the home page of the microsite.

Return value

\Drupal\node\NodeInterface|null Home page node, or null if none exists.

Overrides MicrositeInterface::getHome

File

modules/entity_hierarchy_microsite/src/Entity/Microsite.php, line 115

Class

Microsite
Defines a class for a microsite entity.

Namespace

Drupal\entity_hierarchy_microsite\Entity

Code

public function getHome() {
  return $this
    ->get('home')->entity;
}