File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11# Release Notes for Craft Commerce
22
3+ ## Unreleased
4+
5+ - Fixed a bug where a line item’s sale price could be incorrectly calculated. ([ #3928 ] ( https://github.com/craftcms/commerce/issues/3928 ) )
6+
37## 4.8.1.2 - 2025-02-10
48
59- Fixed a bug where carts’ adjustment totals could be calculated incorrectly. ([ #3888 ] ( https://github.com/craftcms/commerce/issues/3888 ) )
Original file line number Diff line number Diff line change @@ -610,10 +610,16 @@ public function populateFromPurchasable(PurchasableInterface $purchasable): void
610610 $ ignoreSales = false ;
611611 foreach (Plugin::getInstance ()->getDiscounts ()->getAllActiveDiscounts ($ this ->getOrder ()) as $ discount ) {
612612 if (Plugin::getInstance ()->getDiscounts ()->matchLineItem ($ this , $ discount , true )) {
613+ // Break if matched discount is set to ignore sales.
613614 $ ignoreSales = $ discount ->ignoreSales ;
614615 if ($ ignoreSales ) {
615616 break ;
616617 }
618+
619+ // Break if matched discount is set to not apply any subsequent discounts.
620+ if ($ discount ->stopProcessing ) {
621+ break ;
622+ }
617623 }
618624 }
619625
You can’t perform that action at this time.
0 commit comments