Guest User

Untitled

a guest
Jul 18th, 2018
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. <?php
  2. // Handy method to remove the hook for email notifications of custom post status changes
  3. function ef_remove_post_status_notifications() {
  4. global $edit_flow;
  5. // Edit Flow originally hooks into 'transition_post_status' to know when to send custom post status notifications
  6. remove_action( 'transition_post_status', array( &$edit_flow->notifications, 'notification_status_change' ), 10, 3 );
  7. }
  8. // Hook this action into init so Edit Flow is already loaded
  9. add_action( 'init', 'ef_remove_post_status_notifications' );
  10. ?>
Add Comment
Please, Sign In to add comment