XMLRPC: Fix the featured image support in mw_newPost to use the correct variable names. See #18429 and [UT592].

git-svn-id: https://develop.svn.wordpress.org/trunk@20321 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Peter Westwood 2012-03-29 11:06:17 +00:00
parent 8c171a54c6
commit f7ef53292c
1 changed files with 2 additions and 2 deletions

View File

@ -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'] );