diff --git a/wp-includes/post.php b/wp-includes/post.php index 2ca5f3cc62..630b9b3494 100644 --- a/wp-includes/post.php +++ b/wp-includes/post.php @@ -5178,8 +5178,7 @@ function set_post_thumbnail( $post, $thumbnail_id ) { if ( $post && $thumbnail_id && get_post( $thumbnail_id ) ) { $thumbnail_html = wp_get_attachment_image( $thumbnail_id, 'thumbnail' ); if ( ! empty( $thumbnail_html ) ) { - update_post_meta( $post->ID, '_thumbnail_id', $thumbnail_id ); - return true; + return update_post_meta( $post->ID, '_thumbnail_id', $thumbnail_id ); } } return false;