This function has been deprecated.

sync_category_tag_slugs( WP_Term|array $term, string $taxonomy )

Synchronizes category and post tag slugs when global terms are enabled.


Parameters

$term

(Required) The term.

$taxonomy

(Required) The taxonomy for $term.


Return

(WP_Term|array) Always returns $term.


Source

File: wp-admin/includes/ms-deprecated.php

function sync_category_tag_slugs( $term, $taxonomy ) {
	if ( global_terms_enabled() && ( $taxonomy == 'category' || $taxonomy == 'post_tag' ) ) {
		if ( is_object( $term ) ) {
			$term->slug = sanitize_title( $term->name );
		} else {
			$term['slug'] = sanitize_title( $term['name'] );
		}
	}
	return $term;
}

Changelog

Changelog
Version Description
6.1.0 This function has been deprecated.
3.0.0 Introduced. This function has been deprecated.