diff --git a/includes/admin/class-wc-admin-taxonomies.php b/includes/admin/class-wc-admin-taxonomies.php index 96aae43223f..74aa5ce1b59 100644 --- a/includes/admin/class-wc-admin-taxonomies.php +++ b/includes/admin/class-wc-admin-taxonomies.php @@ -42,8 +42,8 @@ class WC_Admin_Taxonomies { $attribute_taxonomies = wc_get_attribute_taxonomies(); if ( $attribute_taxonomies ) { - foreach ( array_keys( $attribute_taxonomies ) as $attribute ) { - add_action( $attribute . '_pre_add_form', array( $this, 'product_attribute_description' ) ); + foreach ( $attribute_taxonomies as $attribute ) { + add_action( 'pa_' . $attribute->attribute_name . '_pre_add_form', array( $this, 'product_attribute_description' ) ); } }