I had some contacts who complain of not receiving mailings. In communication preferences, email formats were 'both' for all contacts. Quite by chance, I went to look in the log file, where there were messages:
CiviMail will not send an empty email body, Skipping: xxxxx
After having researched this message in the php code, I analyzed CRM/Mailing/BAO/Mailing.php and saw that the body of the message is deleted if $contact['preferred_mail_format'] is neither Both, Text or HTML.
I went in the database, and for all contacts who did not receive the mailings, I've seen that the preferred_mail_format column contained NULL.
I have corrected by hand and all mails are gone.
I wonder if we should not: - Or, if preferred_mail_format is neither Both, Text or HTML, put a mail contains in a default format (Text, Html,?) - Or, when calculating the number of recipients (in the mailing of the editorial page), display a warning indicating the potential problems.
Regards.