Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 294800

DefaultMailSystem implements MailSystemInterface::format() incorrectly

$
0
0

The current implementation is:

public function format(array $message) {
  // Join the body array into one string.
  $message['body'] = implode("\n\n", $message['body']);
  // Convert any HTML to plain-text.
  $message['body'] = drupal_html_to_text($message['body']);
  // Wrap the mail body for sending.
  $message['body'] = drupal_wrap_mail($message['body']);
  return $message;
}

However, according to the description of drupal_html_to_text(), the call to drupal_wrap_mail() is unnecessary and should be removed since it converts all soft breaks into hard breaks, making format=flowed meaningless.


Viewing all articles
Browse latest Browse all 294800

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>