Don't store a revision for the initial call to wp_insert_post(), only on saves.

In core UI (and XML-RPC), we first create an auto-draft via get_default_post_to_edit(), which means the first "save" is in practice the first revision.

This reverts [23842].

fixes #24708.



git-svn-id: https://develop.svn.wordpress.org/trunk@24650 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin 2013-07-10 22:40:42 +00:00
parent 8bea3243c9
commit 52897ae4b9
1 changed files with 1 additions and 1 deletions

View File

@ -254,7 +254,7 @@ add_action( 'init', 'smilies_init',
add_action( 'plugins_loaded', 'wp_maybe_load_widgets', 0 );
add_action( 'plugins_loaded', 'wp_maybe_load_embeds', 0 );
add_action( 'shutdown', 'wp_ob_end_flush_all', 1 );
add_action( 'wp_insert_post', 'wp_save_post_revision', 10, 1 );
add_action( 'post_updated', 'wp_save_post_revision', 10, 1 );
add_action( 'publish_post', '_publish_post_hook', 5, 1 );
add_action( 'transition_post_status', '_transition_post_status', 5, 3 );
add_action( 'transition_post_status', '_update_term_count_on_transition_post_status', 10, 3 );