[wp-trac] [WordPress Trac] #64368: `Could not instantiate mail function` errors sending mail in 6.9

WordPress Trac noreply at wordpress.org
Wed Dec 10 15:01:37 UTC 2025


#64368: `Could not instantiate mail function` errors sending mail in 6.9
--------------------------+-----------------------
 Reporter:  desrosj       |       Owner:  SirLouen
     Type:  defect (bug)  |      Status:  accepted
 Priority:  normal        |   Milestone:  6.9.1
Component:  Mail          |     Version:  6.9
 Severity:  normal        |  Resolution:
 Keywords:                |     Focuses:
--------------------------+-----------------------

Comment (by zoe20):

 Replying to [comment:36 SirLouen]:
 > Replying to @zoe20
 > > Is there any temporary workaround or patch available that resolves
 this issue while staying on WP 6.9?
 >
 > Yes, if you can add this code in a plugin or `functions.php`
 >
 > {{{#!php
 > add_action( 'phpmailer_init', static function ( $phpmailer ) {
 >         $phpmailer->Sender = '';
 > } );
 > }}}
 >
 > Once 6.9.1 is released, you can remove it.
 >
 Thank you for the suggestion! I’ve created a plugin called WP-Mail-Fix and
 installed it. I tested the New Order Email preview, and everything is
 processing as expected without any issues.

 I appreciate your help in providing a temporary workaround. This solution
 works well, and I’ll keep an eye out for the release of WP 6.9.1 to remove
 the patch once it’s no longer needed.

 Thanks again for your assistance!

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


More information about the wp-trac mailing list