-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sending emails manually error out with white screen (but still sends) #5
Comments
So, my solution to this was to:
at the beginning of the entire plugin (but I'm guessing I could put it at the beginning of the send_wp_mail function, I was just doing this quickly), and then:
at the end of the I'm guessing you guys may not have noticed it because you have output buffering ALWAYS on by default, but since some don't - these pieces of code are important. I never did figure out WHERE the output was coming from since buffering the output was the easiest solution at the time (but removing that output would also fix this issue). |
I see a bug here with |
I couldn't find why it was outputting the array since I just dove into the output buffer fix. But, there are no problems if I deactivate the plugin and there are no problems if I code the output buffer to catch anything the plugin outputs in that function. Maybe the fact that it's a string is what causes the output (for whatever reason)? |
I'll use WooCommerce as an example - if I go to any given order, and try to resend order emails (specifically, in my testing, I used WooCommerce Subscription renewal notices), the plugin sends the email, BUT - it errors out, simply printing the email it sent to, but everything else is a white screen as WP crashes, here's the output:
array(1) { [0]=> string(18) "[email protected]" }
If debug mode is on, then it prints this:
Warning: array_merge(): Argument #2 is not an array in /wp-content/plugins/aws-ses-wp-mail/inc/class-ses.php on line 76
and then echoes out the array:
array(1) { [0]=> string(18) "[email protected]" }
The text was updated successfully, but these errors were encountered: