Docs: Update description for get_categories() to avoid suggesting the deprecated type argument.

Follow-up to [13754].

Props dingo_d.
Fixes #48913.
Built from https://develop.svn.wordpress.org/trunk@46891


git-svn-id: http://core.svn.wordpress.org/trunk@46691 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2019-12-12 16:47:05 +00:00
parent db18e7d50b
commit 99f11a6af2
2 changed files with 6 additions and 9 deletions

View File

@ -9,9 +9,8 @@
/**
* Retrieve list of category objects.
*
* If you change the type to 'link' in the arguments, then the link categories
* will be returned instead. Also all categories will be updated to be backward
* compatible with pre-2.3 plugins and themes.
* If you set the 'taxonomy' argument to 'link_category', the link categories
* will be returned instead.
*
* @since 2.1.0
* @see get_terms() Type of arguments that can be changed.
@ -19,9 +18,9 @@
* @param string|array $args {
* Optional. Arguments to retrieve categories. See get_terms() for additional options.
*
* @type string $taxonomy Taxonomy to retrieve terms for. In this case, default 'category'.
* @type string $taxonomy Taxonomy to retrieve terms for. Default 'category'.
* }
* @return array List of categories.
* @return array List of category objects.
*/
function get_categories( $args = '' ) {
$defaults = array( 'taxonomy' => 'category' );
@ -78,8 +77,6 @@ function get_categories( $args = '' ) {
* If you look at get_term(), then both types will be passed through several
* filters and finally sanitized based on the $filter parameter value.
*
* The category will converted to maintain backward compatibility.
*
* @since 1.5.1
*
* @param int|object $category Category ID or Category row object
@ -336,7 +333,7 @@ function clean_category_cache( $id ) {
}
/**
* Update category structure to old pre 2.3 from new taxonomy structure.
* Update category structure to old pre-2.3 from new taxonomy structure.
*
* This function was added for the taxonomy support to update the new category
* structure with the old category one. This will maintain compatibility with

View File

@ -13,7 +13,7 @@
*
* @global string $wp_version
*/
$wp_version = '5.4-alpha-46887';
$wp_version = '5.4-alpha-46891';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.