Taxonomy: Document that the get_terms filter can have null for $taxonomies.

The `get_terms` filter currently documents that the filter passes an array as both the first and second parameters, which is normally true, except that the second can be `null` when not specified.  This change updates the filter's docblock to indicate that the second parameter can also be of a `null` type.

Props dd32, audrasjb, mukesh27.
Fixes #54222.

git-svn-id: https://develop.svn.wordpress.org/trunk@52131 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
David Baumwald 2021-11-10 21:09:30 +00:00
parent 4160c23106
commit 1e785fa0c3

View File

@ -1330,7 +1330,7 @@ function get_terms( $args = array(), $deprecated = '' ) {
* @since 4.6.0 Added the `$term_query` parameter.
*
* @param array $terms Array of found terms.
* @param array $taxonomies An array of taxonomies.
* @param array|null $taxonomies An array of taxonomies if known.
* @param array $args An array of get_terms() arguments.
* @param WP_Term_Query $term_query The WP_Term_Query object.
*/