Active
Project:
Messaging
Version:
6.x-2.2
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
19 Nov 2009 at 12:55 UTC
Updated:
25 Nov 2009 at 14:23 UTC
If email message body is an array the mail() function in drupal_send_mail causing an error because a string is expected. This is because the Messaging mail handling are passing by drupal_mail which have a check for this. I think it will be a good idea to wrap the body in messaging_mail_prepare. I have added the following line after the alter mail call:
$mail['body'] = is_array($mail['body']) ? implode("\n\n", $mail['body']) : $mail['body'];
Is there any specific reason why drupal_wrap_mail is not called?
Comments
Comment #1
mnlund commented