问答 / 0 / 1 / 创建于 5年前 / 更新于 5年前
我的登陆不在默认的 guard 中在 新建的名为 open 中重设密码时自动寻找了我默认的用户模型
请问如何去设置找回密码使用的模型是我自定义的模型?
如果你使用的是默认的ResetPasswordController的话,重写这个控制器的guard方法,返回你添加的这个guard,你需要在config/auth.php的guards里面使用你新增的这个provider
ResetPasswordController
guard
config/auth.php
guards
provider
protected function guard() { return Auth::guard('你自己添加的guard'); }
我要举报该,理由是:
如果你使用的是默认的
ResetPasswordController
的话,重写这个控制器的guard
方法,返回你添加的这个guard
,你需要在config/auth.php
的guards
里面使用你新增的这个provider