Auth::attempt($credentials) always returns false

前端 未结 3 1439
轮回少年
轮回少年 2021-01-22 06:23

Hi there I am new to laravel and I am trying to code functionality of my login form here are the codes:

this is how I create new user (works well)

public         


        
3条回答
  •  旧巷少年郎
    2021-01-22 07:16

    Fool me! Although I have checked it many times, I could not see the line 'username' => 'email', in auth config file.

    it should be 'username' => 'username', since I am going to use username for login.

提交回复
热议问题