Skip to content

Commit e516ebc

Browse files
committed
Fix static tests.
1 parent 11e5397 commit e516ebc

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

app/code/Magento/SalesRule/Model/ResourceModel/Rule/Collection.php

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,6 @@ public function setValidationFilter(
160160
Address $address = null
161161
) {
162162
if (!$this->getFlag('validation_filter')) {
163-
164163
$this->prepareSelect($websiteId, $customerGroupId, $now);
165164

166165
$noCouponRules = $this->getNoCouponCodeSelect();
@@ -169,7 +168,7 @@ public function setValidationFilter(
169168
$couponRules = $this->getCouponCodeSelect($couponCode);
170169

171170
$allAllowedRules = $this->getConnection()->select();
172-
$allAllowedRules->union([$noCouponRules, $couponRules], \Zend_Db_Select::SQL_UNION_ALL);
171+
$allAllowedRules->union([$noCouponRules, $couponRules], Select::SQL_UNION_ALL);
173172

174173
$wrapper = $this->getConnection()->select();
175174
$wrapper->from($allAllowedRules);
@@ -189,9 +188,9 @@ public function setValidationFilter(
189188
/**
190189
* Recreate the default select object for specific needs of salesrule evaluation with coupon codes.
191190
*
192-
* @param $websiteId
193-
* @param $customerGroupId
194-
* @param $now
191+
* @param int $websiteId
192+
* @param int $customerGroupId
193+
* @param string $now
195194
*/
196195
private function prepareSelect($websiteId, $customerGroupId, $now)
197196
{
@@ -223,7 +222,7 @@ private function getNoCouponCodeSelect()
223222
/**
224223
* Determine all active rules that are valid for the given coupon code.
225224
*
226-
* @param $couponCode
225+
* @param string $couponCode
227226
* @return Select
228227
*/
229228
private function getCouponCodeSelect($couponCode)
@@ -260,7 +259,9 @@ private function getCouponCodeSelect($couponCode)
260259
}
261260

262261
/**
263-
* @param $couponCode
262+
* Join coupong table to select.
263+
*
264+
* @param string $couponCode
264265
* @param Select $couponSelect
265266
*/
266267
private function joinCouponTable($couponCode, Select $couponSelect)

0 commit comments

Comments
 (0)