mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-26 02:57:45 +01:00
Mail: Make the check for empty post title in wp-mail.php
more resilient.
This addresses a regression in [47054], which caused posts sent via email to published with an empty title. Props whyisjake, Otto42, MarkRH, MattyRob, mukesh27, afragen, pikamander2. Merges [47580] to the 5.4 branch. Fixes #49853. Built from https://develop.svn.wordpress.org/branches/5.4@47581 git-svn-id: http://core.svn.wordpress.org/branches/5.4@47356 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
b19630479f
commit
6081c85b6c
@ -13,7 +13,7 @@
|
|||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '5.4.1-alpha-47579';
|
$wp_version = '5.4.1-alpha-47581';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
@ -213,7 +213,7 @@ for ( $i = 1; $i <= $count; $i++ ) {
|
|||||||
|
|
||||||
$post_title = xmlrpc_getposttitle( $content );
|
$post_title = xmlrpc_getposttitle( $content );
|
||||||
|
|
||||||
if ( '' === $post_title ) {
|
if ( '' === trim( $post_title ) ) {
|
||||||
$post_title = $subject;
|
$post_title = $subject;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user