syndication
syndication copied to clipboard
XML Pull Client does not set post_status based on default_post_status
The XML pull client is publishing posts using the syn_post_pull_new_post filter hook. $this->default_post_status is never used to set the post status, which means all posts are run through wp_insert_post with no default post_status (therefore the post status is set to 'draft').
This can result in weird behavior (it allows for the post to have no slug, for example, unless one is explicitly passed as part of the $post data). Since the post is then published by default using the wp_publish_post function (called by publish_pulled_post in class-syndication-wp-xml-client.php, there is no control over the final post_status of the post (it's always 'publish') unless one removes that filter explicitly.