[wp-trac] [WordPress Trac] #35069: Allow short-circuiting wp_mail

WordPress Trac noreply at wordpress.org
Mon Dec 14 08:55:53 UTC 2015


#35069: Allow short-circuiting wp_mail
-------------------------+--------------------------
 Reporter:  DvanKooten   |       Owner:
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  4.5
Component:  Mail         |     Version:  trunk
 Severity:  normal       |  Resolution:
 Keywords:  has-patch    |     Focuses:  performance
-------------------------+--------------------------
Changes (by SergeyBiryukov):

 * keywords:   => has-patch
 * milestone:  Awaiting Review => 4.5


Comment:

 FWIW, it's already possible, this would prevent the email from being sent:
 {{{
 function wp35069_skip_sending_email( $args ) {
         $args['message'] = '';

         return $args;
 }
 add_filter( 'wp_mail', 'wp35069_skip_sending_email' );
 }}}

 However, [attachment:35069.diff] would save some processing time and seems
 like a good idea.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/35069#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list