CommentThreads final class
Minn\Runtime\CommentThreads · public/minn/src/Minn/Runtime/CommentThreads.php · 68 lines
A threaded or flat comment query's descendants as the reference fills them (probe wp-comment-query-sql): one more comment query a level, with the query's own variables but the level's parents, no parent, no limit and no count; a threaded query hangs each reply under its parent, marks every comment's children as known and keeps the top level by id, a flat one lists the top level and then each level in its query's order.
Used by 1
Constants and properties
| private | LEVEL = array ( 'parent' => '', 'hierarchical' => false, 'number' => 0, 'offset' => 0, 'no_found_rows' => true, ) |
Public
| method | fill(WP_Comment_Query $query, array $top): array# | The query's top-level comments with their descendants filled in.
@return array<int, \WP_Comment> | ||||||
| static | flatten(array $children, array $args): array# | A comment's children, then each one's own, depth first, as a list.
@return list<\WP_Comment> |
Nothing matches.