Skip to content

Commit bb5e57e

Browse files
MC-41464: Subtotal not being updated if you are back from multishipping to cart
1 parent 87ded88 commit bb5e57e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

app/code/Magento/Multishipping/Model/Cart/Controller/CartPlugin.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
use Magento\Customer\Api\AddressRepositoryInterface;
1313
use Magento\Framework\App\RequestInterface;
1414
use Magento\Framework\Exception\LocalizedException;
15-
use Magento\Multishipping\Model\Checkout\Type\Multishipping\State;
1615
use Magento\Multishipping\Model\DisableMultishipping;
1716
use Magento\Quote\Api\CartRepositoryInterface;
1817
use Magento\Quote\Model\Quote;
@@ -73,7 +72,8 @@ public function beforeDispatch(Cart $subject, RequestInterface $request)
7372
{
7473
/** @var Quote $quote */
7574
$quote = $this->checkoutSession->getQuote();
76-
if ($quote->isMultipleShippingAddresses() || $quote->getIsMultiShipping()) {
75+
if ($quote->isMultipleShippingAddresses()
76+
|| ($request->getActionName() !== "add" && $quote->getIsMultiShipping())) {
7777
$this->disableMultishipping->execute($quote);
7878
foreach ($quote->getAllShippingAddresses() as $address) {
7979
$quote->removeAddress($address->getId());

0 commit comments

Comments
 (0)