You are here

public function Domain::enable in Domain Access 8

Enables the configuration entity.

Return value

$this

Overrides ConfigEntityBase::enable

File

domain/src/Entity/Domain.php, line 233

Class

Domain
Defines the domain entity.

Namespace

Drupal\domain\Entity

Code

public function enable() {
  $this
    ->setStatus(TRUE);
  $this
    ->setHostname($this
    ->getCanonical());
  $this
    ->save();
}