我正在处理单击链接后重定向未登录客户的功能设置多个地址我试图用文件目录修改供应商中的文件/vendor/magento/module-multishipping/Controller/Checkout但是当我再次单击链接时它向我显示 404 错误。这里是我要更改的代码
<?php
/**
*
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
namespace Magento\Multishipping\Controller\Checkout;
class Login extends \Magento\Multishipping\Controller\Checkout
{
/**
* Multishipping checkout login page
*
* @return void
*/
public function execute()
{
if ($this->_objectManager->get(\Magento\Customer\Model\Session::class)->isLoggedIn()) {
$this->_redirect('*/*/');
return;
}
$this->_view->loadLayout();
// set account create url
$loginForm = $this->_view->getLayout()->getBlock('customer.new');
if ($loginForm) {
$loginForm->setCreateAccountUrl($this->_getHelper()->getMSRegisterUrl());
}
$this->_view->renderLayout();
}
}
如何修改此文件以使用户在未登录的情况下重定向到地址页面?