Miller-Media / send-emails-with-mandrill

A fork of the official wpMandrill plugin for Wordpress, since it is no longer being actively supported.
21 stars 16 forks source link

Added the ability to set $message['force_skip'] to force plugin to bail #73

Open mt-gareth opened 4 years ago

mt-gareth commented 4 years ago

I needed the ability to set a flag to tell Mandrill to bail before sending the message so that I could delay the sending until after Shutdown.

MillerMedia commented 4 years ago

Hi @mt-gareth , thanks for the submission. Can you clarify what you mean by 'after Shutdown'? Shutdown of what?

mt-gareth commented 4 years ago

By shutdown I mean the "shutdown" action that WordPress does after it sends the page to the user, allowing for me to do all the email work after the client has already received the HTML. So I am jumping in right before Mandrill sends the emails, copying the message, and telling it not to send now. After WordPress is done it sends the HTML to the user and then runs shutdown, I jump in and tell it to send the messages now.