Handle future-scheduled custom post_type's. Props waltervos. Fixes #12842

git-svn-id: http://svn.automattic.com/wordpress/trunk@14056 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
dd32 2010-04-10 12:17:19 +00:00
parent 14e2cb8f6e
commit 0b4ebffe70
2 changed files with 2 additions and 2 deletions

View File

@ -220,8 +220,6 @@ add_action( 'plugins_loaded', 'wp_maybe_load_embeds', 0 );
add_action( 'shutdown', 'wp_ob_end_flush_all', 1 );
add_action( 'pre_post_update', 'wp_save_post_revision' );
add_action( 'publish_post', '_publish_post_hook', 5, 1 );
add_action( 'future_post', '_future_post_hook', 5, 2 );
add_action( 'future_page', '_future_post_hook', 5, 2 );
add_action( 'save_post', '_save_post_hook', 5, 2 );
add_action( 'transition_post_status', '_transition_post_status', 5, 3 );
add_action( 'comment_form', 'wp_comment_form_unfiltered_html_nonce' );

View File

@ -892,6 +892,8 @@ function register_post_type($post_type, $args = array()) {
$wp_post_types[$post_type] = $args;
add_action( 'future_' . $post_type, '_future_post_hook', 5, 2 );
foreach ( $args->taxonomies as $taxonomy ) {
register_taxonomy_for_object_type( $taxonomy, $post_type );
}