update_termmeta_cache()WP 4.4.0

Updates metadata cache for list of term IDs.

Performs SQL query to retrieve all metadata for the terms matching $term_ids and stores them in the cache. Subsequent calls to get_term_meta() not need to query the database.

No Hooks.

Return

Array|false. An array of metadata on success, false if there is nothing to update.

Usage

update_termmeta_cache( $term_ids );
$term_ids(array) (required)
List of term IDs.

Changelog

Since 4.4.0 Introduced.

update_termmeta_cache() code WP 6.5.2

function update_termmeta_cache( $term_ids ) {
	return update_meta_cache( 'term', $term_ids );
}