Update class-wc-cart.php

This commit is contained in:
Andrew Benbow 2014-03-28 10:41:17 +00:00 committed by Mike Jolley
parent caa382a611
commit df9a876e87
1 changed files with 12 additions and 1 deletions

View File

@ -1352,7 +1352,18 @@ class WC_Cart {
}
}
return apply_filters( 'woocommerce_cart_needs_shipping', $needs_shipping );
return $needs_shipping;
}
/**
* Show the shipping address form even if the cart contains virtual products
*
* @return bool
*
* Use add_filter( 'woocommerce_needs_shipping_address', '__return_true' ); to override
*/
function needs_shipping_address() {
return apply_filters( 'woocommerce_needs_shipping_address', false );
}
/**