Pass $update to the save_post and wp_insert_post hooks in wp_insert_post(). props ericmann, fixes #21450.

git-svn-id: http://core.svn.wordpress.org/trunk@24823 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Andrew Nacin 2013-07-28 21:05:25 +00:00
parent 5857eb099e
commit aa6d93cd3e
1 changed files with 2 additions and 2 deletions

View File

@ -2872,8 +2872,8 @@ function wp_insert_post($postarr, $wp_error = false) {
do_action( 'post_updated', $post_ID, $post_after, $post_before); do_action( 'post_updated', $post_ID, $post_after, $post_before);
} }
do_action('save_post', $post_ID, $post); do_action( 'save_post', $post_ID, $post, $update );
do_action('wp_insert_post', $post_ID, $post); do_action( 'wp_insert_post', $post_ID, $post, $update );
return $post_ID; return $post_ID;
} }