Remove unnecessary array_reverse() from wp_get_post_revisions().

WP_Query properly handles multiple 'orderby' values since [28541].

fixes #26042.
Built from https://develop.svn.wordpress.org/trunk@28543


git-svn-id: http://core.svn.wordpress.org/trunk@28369 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2014-05-22 18:51:14 +00:00
parent e4bc49c244
commit fdaa694ac7

View File

@ -417,7 +417,7 @@ function wp_get_post_revisions( $post_id = 0, $args = null ) {
if ( ! $post || empty( $post->ID ) )
return array();
$defaults = array( 'order' => 'ASC', 'orderby' => 'date ID', 'check_enabled' => true );
$defaults = array( 'order' => 'DESC', 'orderby' => 'date ID', 'check_enabled' => true );
$args = wp_parse_args( $args, $defaults );
if ( $args['check_enabled'] && ! wp_revisions_enabled( $post ) )
@ -428,8 +428,6 @@ function wp_get_post_revisions( $post_id = 0, $args = null ) {
if ( ! $revisions = get_children( $args ) )
return array();
$revisions = array_reverse( $revisions );
return $revisions;
}