From f9d356a488b1e892629f3830de70b87bb706cfd7 Mon Sep 17 00:00:00 2001 From: 0xenm21 <123464266+0xenm21@users.noreply.github.com> Date: Tue, 24 Jan 2023 15:36:57 +0400 Subject: [PATCH] fixed the minSpend condition on Discount (#823) Co-authored-by: mouhcine --- packages/core/src/DiscountTypes/Discount.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/src/DiscountTypes/Discount.php b/packages/core/src/DiscountTypes/Discount.php index 112f7644c2..f110e33249 100644 --- a/packages/core/src/DiscountTypes/Discount.php +++ b/packages/core/src/DiscountTypes/Discount.php @@ -37,7 +37,7 @@ public function apply(Cart $cart): Cart $lines = $this->getEligibleLines($cart); - if (! $passes || ($minSpend && $minSpend < $lines->sum('subTotal.value'))) { + if (! $passes || ($minSpend && $minSpend >= $lines->sum('subTotal.value'))) { return $cart; }