Get the right number of pages then excluding a tree, fixes #11205
git-svn-id: http://svn.automattic.com/wordpress/trunk@12279 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
fc341ce3ab
commit
5f74404560
|
@ -2599,6 +2599,7 @@ function &get_pages($args = '') {
|
|||
foreach ( $children as $child )
|
||||
$excludes[] = $child->ID;
|
||||
$excludes[] = $exclude;
|
||||
$num_pages = count($pages);
|
||||
for ( $i = 0; $i < $num_pages; $i++ ) {
|
||||
if ( in_array($pages[$i]->ID, $excludes) )
|
||||
unset($pages[$i]);
|
||||
|
|
Loading…
Reference in New Issue