From 10f3ff17539e162f895eac4ff6196e50fdec6720 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Sun, 1 Nov 2015 00:49:24 +0000 Subject: [PATCH] Post List Table: Hierarchical post types should not default to sorting by date. Regression introduced in [34728]. Props ellie.roepken. Fixes #34473. See #25493. Built from https://develop.svn.wordpress.org/trunk@35482 git-svn-id: http://core.svn.wordpress.org/trunk@35446 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/includes/post.php | 2 +- wp-includes/version.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-admin/includes/post.php b/wp-admin/includes/post.php index fa86377dbe..4e2bc39793 100644 --- a/wp-admin/includes/post.php +++ b/wp-admin/includes/post.php @@ -1008,7 +1008,7 @@ function wp_edit_posts_query( $q = false ) { $orderby = $q['orderby']; } elseif ( isset( $q['post_status'] ) && in_array( $q['post_status'], array( 'pending', 'draft' ) ) ) { $orderby = 'modified'; - } else { + } elseif ( ! is_post_type_hierarchical( $post_type ) ) { $orderby = 'date'; } diff --git a/wp-includes/version.php b/wp-includes/version.php index 048bd47246..5c87a1225b 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.4-beta2-35481'; +$wp_version = '4.4-beta2-35482'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.