1
我想限制我的登錄嘗試,但仍然沒有工作laravel 5.4的登錄嘗試不工作
<?php
namespace App\Http\Controllers\Auth;
use App\Http\Controllers\Controller;
use Illuminate\Foundation\Auth\AuthenticatesUsers;
class LoginController extends Controller
{
use AuthenticatesUsers;
protected $redirectTo = '/home';
public function __construct()
{
$this->middleware('guest', ['except' => 'logout']);
}
}
,這是ThrottlesLogin.php
protected function hasTooManyLoginAttempts(Request $request)
{
return $this->limiter()->tooManyAttempts(
$this->throttleKey($request), 3, 2
);
}
,我知道在laravel 5.4 AuthenticatesUsers默認調用thethrottlesLogin,但仍然不限制登錄嘗試。 和感謝