I have create new login step in magento 2 checkout. When i add product to cart ,goto checkout and login from step guest user cart not merge with logged in user cart. Below is the code for login.

$customer = $this->customerAccountManagement->authenticate(
            $redirectRoute = $this->getAccountRedirect()->getRedirectCookie();
            if (!$this->getScopeConfig()->getValue('customer/startup/redirect_dashboard') && $redirectRoute) {
                $response['redirectUrl'] = $this->_redirect->success($redirectRoute);
| improve this question | | | | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.