【发布时间】:2015-10-13 18:04:11
【问题描述】:
运行 php artisan tinker 后,我创建了一个用户:
App\User::create(['email' => 'test@test.com', 'password' => '123456'])
=> App\User {#723
email: "test@test.com",
updated_at: "2015-10-13 17:33:58",
created_at: "2015-10-13 17:33:58",
id: 6,
}
为什么下面的命令返回false?
Auth::attempt(['email' => 'test@test.com', 'password' => '123456'])
=> false
Auth::attempt 应该如何使用?
【问题讨论】: