Double email on Post update
-
Hi,
I figured out how/why some people are seeing double e-mails on a post Update. We’re using Customify theme and Profile Builder. Enabling either would cause the problem.
When the Update button is hit, the post.php script gets called two times. The first time does the content update, the second time does Meta data updates. Both times trigger the ‘publish_to_publish’ action.
In the bnfw->update_post function, add the following test:
if ( isset($_GET) && count($_GET) > 0 && isset($_GET['meta-box-loader']) ) { return; }
This will prevent meta-data updates from triggering a second e-mail.
I’ve only debugged this one occurance, so if anyone is having problems with double emails someplace else, this may or may not solve it.
Hope this helps,
Brad M.
- The topic ‘Double email on Post update’ is closed to new replies.