Skip to content

Commit 9703475

Browse files
committed
ACP2E-3296: Checkout order email confirmation is sent to emails entered in First/Last name
1 parent d1f8a4d commit 9703475

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

app/code/Magento/Quote/Model/CustomerManagement.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,11 @@ public function validateAddresses(QuoteEntity $quote)
153153
$addresses[] = $this->customerAddressRepository->getById(
154154
$quote->getBillingAddress()->getCustomerAddressId()
155155
);
156+
}
157+
if ($quote->getShippingAddress()->getCustomerAddressId()) {
158+
$addresses[] = $this->customerAddressRepository->getById(
159+
$quote->getShippingAddress()->getCustomerAddressId()
160+
);
156161
} else {
157162
$billingAddress = $quote->getBillingAddress();
158163
$customerAddress = $this->customerAddressFactory->create();
@@ -166,11 +171,6 @@ public function validateAddresses(QuoteEntity $quote)
166171
$customerAddress->setCustomAttributes($billingAddress->getCustomAttributes());
167172
$addresses[] = $customerAddress;
168173
}
169-
if ($quote->getShippingAddress()->getCustomerAddressId()) {
170-
$addresses[] = $this->customerAddressRepository->getById(
171-
$quote->getShippingAddress()->getCustomerAddressId()
172-
);
173-
}
174174

175175
foreach ($addresses as $address) {
176176
$validator = $this->validatorFactory->createValidator('customer_address', 'save');

0 commit comments

Comments
 (0)