Merge pull request #5418 from tamarazuk/backorders_allowed
Introduce woocommerce_product_backorders_allowed filter
This commit is contained in:
commit
63fc4262b6
|
@ -536,7 +536,7 @@ class WC_Product {
|
|||
* @return bool
|
||||
*/
|
||||
public function backorders_allowed() {
|
||||
return $this->backorders === 'yes' || $this->backorders === 'notify' ? true : false;
|
||||
return apply_filters( 'woocommerce_product_backorders_allowed', $this->backorders === 'yes' || $this->backorders === 'notify' ? true : false, $this->id );
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue