Respect the fields arg when passed to get_children().

Fixes #22208.



git-svn-id: https://develop.svn.wordpress.org/trunk@25160 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Scott Taylor
2013-08-29 15:07:59 +00:00
parent 95cab73341
commit 744a4a80a4
2 changed files with 15 additions and 1 deletions
+4 -1
View File
@@ -311,9 +311,12 @@ function get_children($args = '', $output = OBJECT) {
$children = get_posts( $r );
if ( !$children )
if ( ! $children )
return $kids;
if ( ! empty( $r['fields'] ) )
return $children;
update_post_cache($children);
foreach ( $children as $key => $child )