diff --git a/wp-admin/post.php b/wp-admin/post.php index ba43eb1c2b..174a949d35 100644 --- a/wp-admin/post.php +++ b/wp-admin/post.php @@ -254,13 +254,12 @@ case 'delete': if ( ! current_user_can( 'delete_post', $post_id ) ) wp_die( __( 'You are not allowed to delete this item.' ) ); - $force = ! EMPTY_TRASH_DAYS; if ( $post->post_type == 'attachment' ) { - $force = ( $force || ! MEDIA_TRASH ); + $force = ( ! MEDIA_TRASH ); if ( ! wp_delete_attachment( $post_id, $force ) ) wp_die( __( 'Error in deleting.' ) ); } else { - if ( ! wp_delete_post( $post_id, $force ) ) + if ( ! wp_delete_post( $post_id, true ) ) wp_die( __( 'Error in deleting.' ) ); } diff --git a/wp-includes/version.php b/wp-includes/version.php index 1dd219b8bf..4170aaf77e 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.4-alpha-34793'; +$wp_version = '4.4-alpha-34794'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.