You are here

public function FlagListItem::getOwnerId in Flag Lists 8

Same name and namespace in other branches
  1. 4.0.x src/Entity/FlagListItem.php \Drupal\flag_lists\Entity\FlagListItem::getOwnerId()

Returns the entity owner's user ID.

Return value

int|null The owner user ID, or NULL in case the user ID field has not been set on the entity.

Overrides EntityOwnerInterface::getOwnerId

File

src/Entity/FlagListItem.php, line 116

Class

FlagListItem
Defines the Flag list item entity.

Namespace

Drupal\flag_lists\Entity

Code

public function getOwnerId() {
  return $this
    ->get('user_id')->target_id;
}