Fires after a PHPMailer\PHPMailer\Exception is caught.
$errorWP_Errorwp-includes/pluggable.php:415wp_mail()wp-includes/pluggable.php:582wp_mail() * * @since 4.4.0 * * @param WP_Error $error A WP_Error object with the PHPMailer\PHPMailer\Exception message, and an array * containing the mail recipient, subject, message, headers, and attachments. */ do_action( 'wp_mail_failed', new WP_Error( 'wp_mail_failed', $e->getMessage(), $mail_data ) ); return false; } }endif;Introduced in 4.4.0. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.