Skip to content

Commit

Permalink
Merge pull request #7734 from magento-gl/245_regression_issue
Browse files Browse the repository at this point in the history
245 regression issue
  • Loading branch information
sidolov authored Jun 19, 2022
2 parents 315a517 + 9268f0a commit 9b50069
Showing 1 changed file with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -81,12 +81,13 @@ private function getPaymentMethodsData(CartInterface $cart): array
*/
if ((int)$grandTotal === 0 && $carrierCode === self::FREE_SHIPPING_METHOD
&& $paymentMethod->getCode() === self::FREE_PAYMENT_METHOD_CODE) {
$paymentMethodsData[] = [
'title' => $paymentMethod->getTitle(),
'code' => $paymentMethod->getCode(),
return [
[
'title' => $paymentMethod->getTitle(),
'code' => $paymentMethod->getCode(),
]
];
} elseif ((int)$grandTotal >= 0
&& $carrierCode !== self::FREE_SHIPPING_METHOD) {
} elseif ((int)$grandTotal >= 0) {
$paymentMethodsData[] = [
'title' => $paymentMethod->getTitle(),
'code' => $paymentMethod->getCode(),
Expand Down

0 comments on commit 9b50069

Please sign in to comment.