Our use case: We have a source site with multiple custom post types. We would like to push these custom post types to a remote site as a simple posts.
Applying a filter to the variable at here does the trick.
from
$post_type = get_post_type( $post_id );
to
$post_type = apply_filters( 'dt_push_post_type', get_post_type( $post_id ) );
Happy to submit a PR if this sounds like a good idea.
Our use case: We have a source site with multiple custom post types. We would like to push these custom post types to a remote site as a simple posts.
Applying a filter to the variable at here does the trick.
from
$post_type = get_post_type( $post_id );to
$post_type = apply_filters( 'dt_push_post_type', get_post_type( $post_id ) );Happy to submit a PR if this sounds like a good idea.