File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
app/code/Magento/Sales/Model/Order/Creditmemo/Total Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -134,8 +134,8 @@ public function collect(Creditmemo $creditmemo)
134
134
$ baseShippingDiscountTaxCompensationAmount = 0 ;
135
135
$ shippingDelta = $ baseOrderShippingAmount - $ baseOrderShippingRefundedAmount ;
136
136
137
- if ($ shippingDelta > $ creditmemo ->getBaseShippingAmount () ||
138
- $ this ->isShippingIncludeTaxWithTaxAfterDiscount ($ order ->getStoreId ())) {
137
+ if ($ orderShippingAmount > 0 && ( $ shippingDelta > $ creditmemo ->getBaseShippingAmount () ||
138
+ $ this ->isShippingIncludeTaxWithTaxAfterDiscount ($ order ->getStoreId ()))) {
139
139
$ part = $ creditmemo ->getShippingAmount () / $ orderShippingAmount ;
140
140
$ basePart = $ creditmemo ->getBaseShippingAmount () / $ baseOrderShippingAmount ;
141
141
$ shippingTaxAmount = $ order ->getShippingTaxAmount () * $ part ;
You can’t perform that action at this time.
0 commit comments