Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
0 votes
in Q2A Core by

Found this error in my error logs: 

PHP Question2Answer email send error: You must provide at least one recipient email address.

It derives from the class.phpmailer.php: 

if ((count($this->to) + count($this->cc) + count($this->bcc)) < 1) {
          throw new phpmailerException($this->lang('provide_address'), self::STOP_CRITICAL);

It happened when I did a mass-mailing from the admin panel. 

But checking my users, there are none that have empty email addresses. What could be the reason?

1 Answer

+1 vote
That doesn't mean there is an empty email address but rather the recipient arrays are empty. When filling those with actual email addresses the PHPMailer class performs some filters on its own. Maybe there is an email address that Q2A filters assumed to be valid (that's why it is actually present) but the PHPMailer filters rejected it, so it didn't get to the recipient arrays.

If that assumption is correct, then I guess Q2A should use PHPMailer's filters when validating email addresses.