在Forgot Password中提交请求时 Laravel 5.3.6 中的问题 .
Error Details
调用未定义的方法Illuminate \ Database \ Query \ Builder :: notify()
Issue is in below file:
vendor \ laravel \ framework \ src \ Illuminate \ Auth \ Passwords \ PasswordBroker.php
Line 69. Code is below
$user->sendPasswordResetNotification(
$this->tokens->create($user)
);
Function: sendResetLink
它在 Laravel 5.2 中运行良好,似乎无法在 5.3.6 版本中运行 . 你遇到过这个问题吗?
3 回答
您必须在
User
模型中添加Illuminate\Notifications\Notifiable
特征 .Illuminate\Notifications\Notifiable
对于您的提供商:
Illuminate\Notifications\NotificationServiceProvider::class,
在别名中:
'Notification' => Illuminate\Support\Facades\Notification::class,
就我而言,在按照其他答案中给出的步骤后,我仍然会收到错误 .
我失踪了