woocommerce_product_get_weight filter Closes #7319
This commit is contained in:
parent
67610286f7
commit
893babaaef
|
@ -701,11 +701,11 @@ class WC_Product {
|
|||
|
||||
/**
|
||||
* Returns the product's weight.
|
||||
*
|
||||
* @todo refactor filters in this class to naming woocommerce_product_METHOD
|
||||
* @return string
|
||||
*/
|
||||
public function get_weight() {
|
||||
return ( $this->weight ) ? $this->weight : '';
|
||||
return apply_filters( 'woocommerce_product_get_weight', $this->weight ? $this->weight : '' );
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue