Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Email.php

function Email::ensureBodyValid

2 calls to Email::ensureBodyValid()
Email::ensureValidity in vendor/symfony/mime/Email.php
Email::generateBody in vendor/symfony/mime/Email.php
Generates an AbstractPart based on the raw body of a message.

File

vendor/symfony/mime/Email.php, line 402

Class

Email
@author Fabien Potencier <fabien@symfony.com>

Namespace

Symfony\Component\Mime

Code

private function ensureBodyValid() : void {
    if (null === $this->text && null === $this->html && !$this->attachments) {
        throw new LogicException('A message must have a text or an HTML part or attachments.');
    }
}
RSS feed
Powered by Drupal