mirror of
https://github.com/WordPress/WordPress.git
synced 2025-01-03 15:08:10 +01:00
XMLRPC: Fix the featured image support in mw_newPost to use the correct variable names. See #18429 and [UT592].
git-svn-id: http://svn.automattic.com/wordpress/trunk@20321 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
69f8d3b242
commit
944af3e88b
@ -3753,8 +3753,8 @@ class wp_xmlrpc_server extends IXR_Server {
|
||||
if ( isset($content_struct['custom_fields']) )
|
||||
$this->set_custom_fields($post_ID, $content_struct['custom_fields']);
|
||||
|
||||
if ( isset ( $post_data['wp_featured_image'] ) ) {
|
||||
if ( set_post_thumbnail( $post_ID, $post_data['wp_featured_image'] ) === false )
|
||||
if ( isset ( $content_struct['wp_featured_image'] ) ) {
|
||||
if ( set_post_thumbnail( $post_ID, $content_struct['wp_featured_image'] ) === false )
|
||||
return new IXR_Error( 404, __( 'Invalid attachment ID.' ) );
|
||||
|
||||
unset( $content_struct['wp_featured_image'] );
|
||||
|
Loading…
Reference in New Issue
Block a user