scandipwa / scandipwa

Next-generation front-end for Magento 2

Home Page:https://scandipwa.com/?utm_source=github&utm_medium=readme&utm_campaign=general

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Encountered two list items with same key (CheckoutDeliveryOptions component)

noobCode-69 opened this issue · comments

Steps to reproduce:

  1. Go to the checkout page
  2. Choose a city that have 'ups' service available (Jaipur , India)
  3. Open the console you will the error.

Why
The reason is because carrier_code is used as a key , and 'ups' is carrier_code for more than one options you can see the console logs
{carrier_code: 'flatrate', method_code: 'flatrate'}
{carrier_code: 'tablerate', method_code: 'bestway'}
{carrier_code: 'ups', method_code: 'XPD'}
{carrier_code: 'ups', method_code: 'WXS'}

Expected result
No Errors

Propose solution
We can use the string combinary of carrier_code and method_code for resolve this issue

I am assigning this task to me!