File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
app/code/Magento/SalesRule/Plugin Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -27,6 +27,7 @@ class CartTotalRepository
27
27
* @var \Magento\SalesRule\Model\Coupon
28
28
*/
29
29
private $ coupon ;
30
+
30
31
/**
31
32
* @var StoreManagerInterface
32
33
*/
@@ -55,6 +56,8 @@ public function __construct(
55
56
* @param \Magento\Quote\Model\Cart\CartTotalRepository $subject
56
57
* @param \Magento\Quote\Api\Data\TotalsInterface $result
57
58
* @return \Magento\Quote\Api\Data\TotalsInterface
59
+ *
60
+ * @SuppressWarnings(PHPMD.UnusedFormalParameter)
58
61
*/
59
62
public function afterGet (
60
63
\Magento \Quote \Model \Cart \CartTotalRepository $ subject ,
@@ -86,7 +89,6 @@ public function afterGet(
86
89
87
90
/* @var $label \Magento\SalesRule\Model\Data\RuleLabel */
88
91
foreach ($ rule ->getStoreLabels () as $ label ) {
89
-
90
92
if ($ label ->getStoreId () === 0 ) {
91
93
$ storeLabelFallback = $ label ->getStoreLabel ();
92
94
}
@@ -98,9 +100,7 @@ public function afterGet(
98
100
}
99
101
100
102
$ extensionAttributes ->setCouponLabel (($ storeLabel ) ? $ storeLabel : $ storeLabelFallback );
101
-
102
103
$ result ->setExtensionAttributes ($ extensionAttributes );
103
-
104
104
return $ result ;
105
105
}
106
106
}
You can’t perform that action at this time.
0 commit comments