Skip to content

Commit ad2f9b0

Browse files
irenelagnoisitnikov
authored andcommitted
MAGETWO-51390: Private Data of Registered Customer May Be Retrieved with Quote Web API by Anonymous
1 parent 2f7b621 commit ad2f9b0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,13 +269,13 @@ public function assignCustomer($cartId, $customerId, $storeId)
269269

270270
$quote->setCustomer($customer);
271271
$quote->setCustomerIsGuest(0);
272-
$this->quoteRepository->save($quote);
273272
$quoteIdMaskFactory = $this->getQuoteIdMaskFactory();
274273
/** @var \Magento\Quote\Model\QuoteIdMask $quoteIdMask */
275274
$quoteIdMask = $quoteIdMaskFactory->create()->load($cartId, 'quote_id');
276275
if ($quoteIdMask->getId()) {
277276
$quoteIdMask->delete();
278277
}
278+
$this->quoteRepository->save($quote);
279279
return true;
280280

281281
}

0 commit comments

Comments
 (0)