From af7823605c00a491afd8ee60e47fbbda4e80e26b Mon Sep 17 00:00:00 2001 From: iFlair Date: Thu, 4 Dec 2025 16:51:58 +0530 Subject: [PATCH 1/2] Fix missing element in for wp_mail_succeeded filter --- src/wp-includes/pluggable.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wp-includes/pluggable.php b/src/wp-includes/pluggable.php index 8f167ca2b16a8..1d5ee194c9f10 100644 --- a/src/wp-includes/pluggable.php +++ b/src/wp-includes/pluggable.php @@ -618,7 +618,7 @@ function wp_mail( $to, $subject, $message, $headers = '', $attachments = array() */ do_action_ref_array( 'phpmailer_init', array( &$phpmailer ) ); - $mail_data = compact( 'to', 'subject', 'message', 'headers', 'attachments' ); + $mail_data = compact( 'to', 'subject', 'message', 'headers', 'attachments', 'embeds' ); // Send! try { From b982fefd53751ae92429000d8160d0dcd8f38bfc Mon Sep 17 00:00:00 2001 From: SirLouen Date: Thu, 4 Dec 2025 23:55:19 +0100 Subject: [PATCH 2/2] tests: Add missing 'embeds' field to wp_mail test case --- tests/phpunit/tests/pluggable/wpMail.php | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/phpunit/tests/pluggable/wpMail.php b/tests/phpunit/tests/pluggable/wpMail.php index b7ed263b10ded..785c73eccda6e 100644 --- a/tests/phpunit/tests/pluggable/wpMail.php +++ b/tests/phpunit/tests/pluggable/wpMail.php @@ -446,6 +446,7 @@ public function test_phpmailer_exception_thrown() { 'message' => 'Test Message', 'headers' => array(), 'attachments' => array(), + 'embeds' => array(), 'phpmailer_exception_code' => 2, );