Skip to content

Commit 3ae37b3

Browse files
MC-36088: Non-relevant shipping method available for checkout
1 parent 03d5667 commit 3ae37b3

File tree

1 file changed

+6
-1
lines changed
  • app/code/Magento/Checkout/view/frontend/web/js/view

1 file changed

+6
-1
lines changed

app/code/Magento/Checkout/view/frontend/web/js/view/shipping.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,7 @@ define([
282282
option = _.isObject(this.countryOptions) && this.countryOptions[quote.shippingAddress().countryId],
283283
messageContainer = registry.get('checkout.errors').messageContainer;
284284

285-
if (!quote.shippingMethod() || !quote.shippingMethod()['method_code']) {
285+
if (!quote.shippingMethod()) {
286286
this.errorValidationMessage(
287287
$t('The shipping method is missing. Select the shipping method and try again.')
288288
);
@@ -304,6 +304,11 @@ define([
304304
!quote.shippingMethod()['method_code'] ||
305305
!quote.shippingMethod()['carrier_code']
306306
) {
307+
if (!quote.shippingMethod()['method_code']) {
308+
this.errorValidationMessage(
309+
$t('The shipping method is missing. Select the shipping method and try again.')
310+
);
311+
}
307312
this.focusInvalid();
308313

309314
return false;

0 commit comments

Comments
 (0)