rebase code on oct-10-2023

This commit is contained in:
Rachit Bhargava
2023-10-10 17:51:46 -04:00
parent b16ad94b69
commit 8f1a2c3a66
2197 changed files with 184921 additions and 35568 deletions

View File

@@ -162,11 +162,12 @@ class WC_Shipping_Free_Shipping extends WC_Shipping_Method {
if ( in_array( $this->requires, array( 'min_amount', 'either', 'both' ), true ) ) {
$total = WC()->cart->get_displayed_subtotal();
if ( WC()->cart->display_prices_including_tax() ) {
$total = $total - WC()->cart->get_discount_tax();
}
if ( 'no' === $this->ignore_discounts ) {
$total = $total - WC()->cart->get_discount_total();
if ( WC()->cart->display_prices_including_tax() ) {
$total = $total - WC()->cart->get_discount_tax();
}
}
$total = NumberUtil::round( $total, wc_get_price_decimals() );