You appear to be a bot. Output may be restricted
Description
Updates Terms to Taxonomy in cache.
Usage
update_term_cache( $terms, $taxonomy );
Parameters
- $terms
- ( WP_Term[] ) required – Array of term objects to change.
- $taxonomy
- ( string ) optional – Not used.
Returns
void
Source
File name: wordpress/wp-includes/taxonomy.php
Lines:
1 to 11 of 11
function update_term_cache( $terms, $taxonomy = '' ) { foreach ( (array) $terms as $term ) { // Create a copy in case the array was passed by reference. $_term = clone $term; // Object ID should not be cached. unset( $_term->object_id ); wp_cache_add( $term->term_id, $_term, 'terms' ); } }