Comments: in WP_Comment_Query::fill_descendants()
, continue
if there is an empty array in the loop.
See #37416, [38297]. git-svn-id: https://develop.svn.wordpress.org/trunk@38298 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
f6fced867b
commit
2e111412f9
@ -1013,6 +1013,9 @@ class WP_Comment_Query {
|
|||||||
// Prime comment caches for non-top-level comments.
|
// Prime comment caches for non-top-level comments.
|
||||||
$descendant_ids = array();
|
$descendant_ids = array();
|
||||||
for ( $i = 1, $c = count( $levels ); $i <= $c; $i++ ) {
|
for ( $i = 1, $c = count( $levels ); $i <= $c; $i++ ) {
|
||||||
|
if ( empty( $levels[ $i ] ) ) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
$descendant_ids = array_merge( $descendant_ids, $levels[ $i ] );
|
$descendant_ids = array_merge( $descendant_ids, $levels[ $i ] );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user