You are here

protected function EmailHandler::hasHTMLBody in Easy Email 8

Same name and namespace in other branches
  1. 2.0.x src/Service/EmailHandler.php \Drupal\easy_email\Service\EmailHandler::hasHTMLBody()

Parameters

\Drupal\easy_email\Entity\EasyEmailInterface $email:

Return value

bool

File

src/Service/EmailHandler.php, line 375

Class

EmailHandler

Namespace

Drupal\easy_email\Service

Code

protected function hasHTMLBody(EasyEmailInterface $email) {
  return $email
    ->hasField('body_html') && !empty($email
    ->getHtmlBody()) && !empty($email
    ->getHtmlBody()['value']);
}