Only federate posts

This commit is contained in:
Jeremy Dormitzer 2018-10-19 06:49:18 -04:00
parent 7ea1782edf
commit fc01e6beb2

View File

@ -39,6 +39,10 @@ function handle_post_status_change( $new_status, $old_status, $post ) {
Return an object of type Article
*/
function post_to_object( $post ) {
$supported_post_types = array( 'post' );
if ( ! in_array( $post->post_type, $supported_post_types ) ) {
return;
}
setup_postdata( $post );
$permalink = get_permalink( $post );
$summary = null;