diff --git a/wp-includes/taxonomy.php b/wp-includes/taxonomy.php index f161a71818..91ac0cdb24 100644 --- a/wp-includes/taxonomy.php +++ b/wp-includes/taxonomy.php @@ -408,7 +408,7 @@ function is_taxonomy_hierarchical( $taxonomy ) { * @type bool $_builtin This taxonomy is a "built-in" taxonomy. INTERNAL USE ONLY! * Default false. * } - * @return void|WP_Error Void on success, WP_Error object on failure. + * @return WP_Taxonomy|WP_Error The registered taxonomy object on success, WP_Error object on failure. */ function register_taxonomy( $taxonomy, $object_type, $args = array() ) { global $wp_taxonomies; @@ -441,6 +441,8 @@ function register_taxonomy( $taxonomy, $object_type, $args = array() ) { * @param array $args Array of taxonomy registration arguments. */ do_action( 'registered_taxonomy', $taxonomy, $object_type, (array) $taxonomy_object ); + + return $taxonomy_object; } /** diff --git a/wp-includes/version.php b/wp-includes/version.php index 4ecf922a9a..75af121edc 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -13,7 +13,7 @@ * * @global string $wp_version */ -$wp_version = '5.4-alpha-47185'; +$wp_version = '5.4-alpha-47186'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.