Commit 8c412e36db for woocommerce

commit 8c412e36dbdab9280d6242a763b7aff191ace9b4
Author: Marin Atanasov <8436925+tyxla@users.noreply.github.com>
Date:   Wed Dec 10 12:32:54 2025 +0200

    Breadcrumbs: Remove taxonomy name item for brands (#62334)

    * Breadcrumbs: Remove taxonomy name item for custom taxonomies

    * Add changefile(s) from automation for the following project(s): woocommerce

    * Update PHPStan baseline

    * Only exclude for brands

    * Update changelog entry

    * Update PHPStan baseline

    ---------

    Co-authored-by: github-actions <github-actions@github.com>

diff --git a/plugins/woocommerce/changelog/62334-remove-custom-taxonomy-breadcrumb-prefix b/plugins/woocommerce/changelog/62334-remove-custom-taxonomy-breadcrumb-prefix
new file mode 100644
index 0000000000..96f8a5467c
--- /dev/null
+++ b/plugins/woocommerce/changelog/62334-remove-custom-taxonomy-breadcrumb-prefix
@@ -0,0 +1,4 @@
+Significance: patch
+Type: fix
+Comment: Breadcrumbs: Remove taxonomy name item for brands
+
diff --git a/plugins/woocommerce/includes/class-wc-breadcrumb.php b/plugins/woocommerce/includes/class-wc-breadcrumb.php
index f6f6a938b3..c53cbbee7c 100644
--- a/plugins/woocommerce/includes/class-wc-breadcrumb.php
+++ b/plugins/woocommerce/includes/class-wc-breadcrumb.php
@@ -309,7 +309,9 @@ class WC_Breadcrumb {
 		$this_term = $GLOBALS['wp_query']->get_queried_object();
 		$taxonomy  = get_taxonomy( $this_term->taxonomy );

-		$this->add_crumb( $taxonomy->labels->name );
+		if ( 'product_brand' !== $this_term->taxonomy ) {
+			$this->add_crumb( $taxonomy->labels->name );
+		}

 		if ( 0 !== intval( $this_term->parent ) ) {
 			$this->term_ancestors( $this_term->term_id, $this_term->taxonomy );