WooCommerce Exclude specific category - from products tabs

Job ID: 34082932

Budget: $10 – $30 AUD

Hi,
I have this code in functions in child theme and it works fine, I would like to remove

csp_extra_info for specific category and show for all other categories

add_filter( 'woocommerce_product_tabs', 'csp_add_extrainfo_single_product',10 );
function csp_add_extrainfo_single_product( $tabs ) {
$tabs['csp_extra_info'] = array(
'title' => __( 'Extra Info', 'woocommerce' ),
'priority' => 10,
'callback' => 'csp_extra_info_data'
);
$tabs['csp_safety_info'] = array(
'title' => __( 'Safety Info', 'woocommerce' ),
'priority' => 16,
'callback' => 'csp_safety_info_data'
);
return $tabs;
}
Related categories: WordPress WooCommerce