"Unstick" posts when deleting, fixes #8860

git-svn-id: https://develop.svn.wordpress.org/trunk@10363 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Ozz 2009-01-15 00:47:56 +00:00
parent f36563c215
commit 05e015dbf7
1 changed files with 2 additions and 0 deletions

View File

@ -1131,6 +1131,8 @@ function wp_delete_post($postid = 0) {
$children = $wpdb->get_results($children_query);
$wpdb->update( $wpdb->posts, $parent_data, $parent_where + array( 'post_type' => 'page' ) );
} else {
unstick_post($postid);
}
// Do raw query. wp_get_post_revisions() is filtered