Skip to content

Commit cf24f76

Browse files
authored
Remove redundant check in if-condition
Removed the part of an `if`-condition that tests whether a quote is virtual or not. The part that was removed is redundant because of line 43.
1 parent 9ed7c7d commit cf24f76

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: app/code/Magento/Quote/Model/QuoteValidator.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ public function validateBeforeSubmit(QuoteEntity $quote)
5151
}
5252
$method = $quote->getShippingAddress()->getShippingMethod();
5353
$rate = $quote->getShippingAddress()->getShippingRateByCode($method);
54-
if (!$quote->isVirtual() && (!$method || !$rate)) {
54+
if (!$method || !$rate) {
5555
throw new \Magento\Framework\Exception\LocalizedException(__('Please specify a shipping method.'));
5656
}
5757
}

0 commit comments

Comments
 (0)