woocommerce_api_edit_product_attribute

woocommerce_api_edit_product_attribute

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: action

See hook in core

Displaying hooks found in version: woocommerce.8.7.0

do_action('woocommerce_api_edit_product_attribute') is found 2 times:

  • /includes/legacy/api/v2/class-wc-api-products.php line 2108
    			if ( false === $update ) {
    				throw new WC_API_Exception( 'woocommerce_api_cannot_edit_product_attribute', __( 'Could not edit the attribute', 'woocommerce' ), 400 );
    			}
    
    			do_action( 'woocommerce_api_edit_product_attribute', $id, $data );
    
    			// Clear transients
    			delete_transient( 'wc_attribute_taxonomies' );
    			WC_Cache_Helper::invalidate_cache_group( 'woocommerce-attributes' );
    
    			return $this->get_product_attribute( $id );
    
  • /includes/legacy/api/v3/class-wc-api-products.php line 2662
    			if ( false === $update ) {
    				throw new WC_API_Exception( 'woocommerce_api_cannot_edit_product_attribute', __( 'Could not edit the attribute', 'woocommerce' ), 400 );
    			}
    
    			do_action( 'woocommerce_api_edit_product_attribute', $id, $data );
    
    			// Clear transients.
    			wp_schedule_single_event( time(), 'woocommerce_flush_rewrite_rules' );
    			delete_transient( 'wc_attribute_taxonomies' );
    			WC_Cache_Helper::invalidate_cache_group( 'woocommerce-attributes' );