Add a filter on is_free_shipping function
-
There are no filters available to modify the free delivery rule in this file:
/bpost-shipping/classes/options/class-wc-bpost-shipping-options-base.php
line 192Adding a small line of code could provide greater flexibility for shop managers.
public function is_free_shipping( $country_iso_2, $amount, array $free_shipping_coupons ) {
// Apply a filter to determine if free shipping should be applied
$free_shipping = apply_filters('wc_bpost_is_free_shipping', false, $country_iso_2, $amount, $free_shipping_coupons);
return $free_shipping
|| $this->is_free_country_for_amount( $country_iso_2, $amount )
|| $this->has_free_shipping_coupon( $free_shipping_coupons );
}
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- You must be logged in to reply to this topic.