You are here

public function Vote::getVotedEntityType in Voting API 8.3

Returns the type of entity that the vote was cast on.

Return value

string The entity type.

Overrides VoteInterface::getVotedEntityType

1 call to Vote::getVotedEntityType()
Vote::postSave in src/Entity/Vote.php
Acts on a saved entity before the insert or update hook is invoked.

File

src/Entity/Vote.php, line 54

Class

Vote
Defines the Vote entity.

Namespace

Drupal\votingapi\Entity

Code

public function getVotedEntityType() {
  return $this
    ->get('entity_type')->value;
}