You are here

public function SmsMessage::getRecipientEntity in SMS Framework 8

Same name and namespace in other branches
  1. 2.x src/Entity/SmsMessage.php \Drupal\sms\Entity\SmsMessage::getRecipientEntity()
  2. 2.1.x src/Entity/SmsMessage.php \Drupal\sms\Entity\SmsMessage::getRecipientEntity()

Gets the entity who will receive the SMS message.

Return value

\Drupal\Core\Entity\EntityInterface|null The entity who will receive the SMS message, or NULL if it is missing.

Overrides SmsMessageInterface::getRecipientEntity

File

src/Entity/SmsMessage.php, line 379

Class

SmsMessage
Defines the SMS message entity.

Namespace

Drupal\sms\Entity

Code

public function getRecipientEntity() {
  return $this
    ->get('recipient_entity')->entity;
}