You are here

public function UserModuleStatus::setOwner in Opigno module 8

Same name and namespace in other branches
  1. 3.x src/Entity/UserModuleStatus.php \Drupal\opigno_module\Entity\UserModuleStatus::setOwner()

Sets the entity owner's user entity.

Parameters

\Drupal\user\UserInterface $account: The owner user entity.

Return value

$this

Overrides EntityOwnerInterface::setOwner

File

src/Entity/UserModuleStatus.php, line 123

Class

UserModuleStatus
Defines the User module status entity.

Namespace

Drupal\opigno_module\Entity

Code

public function setOwner(UserInterface $account) {
  $this
    ->set('user_id', $account
    ->id());
  return $this;
}