Closed
Description
Preconditions (*)
- Magento 2.3.3 or 2.4-develop
- Logged in Customer with an Address marked both as Shipping and as Billing.
Steps to reproduce (*)
-
Add a product to cart and go to the second step of checkout.
-
Open developer console and change billing address. e.g.
require('Magento_Checkout/js/model/quote').billingAddress().street[0] = '123 Main Street'
Expected result (*)
- Shipping Address remains the same
Actual result (*)
- Shipping address street is changed to "123 Main Street"
Cloning Issue
The issue is here app/code/Magento/Checkout/view/frontend/web/js/action/select-billing-address.js#L21
and can be fixed by replacing:
address = $.extend({}, billingAddress);
to
address = $.extend(true, {}, billingAddress);
to clone address recursively including the street array.