Private AccessPrivate Access
This function’s access is marked private. This means it is not intended for use by plugin or theme developers, only in other core functions. It is listed here for completeness.
Get the subset of $terms that are descendants of $term_id.
(int) (Required) The ancestor term: all returned terms should be descendants of
(array) (Required) The set of terms - either an array of term objects or term IDs - from which those that are descendants of $term_id will be chosen.
(string) (Required) The taxonomy which determines the hierarchy of the terms.
(array) (Optional) Term ancestors that have already been identified. Passed by reference, to keep track of found terms when recursing the hierarchy. The array of located ancestors is used to prevent infinite recursion loops. For performance,
term_idsare used as array keys, with 1 as value.
Default value: array()
(array|WP_Error) The subset of $terms that are descendants of $term_id.