【发布时间】:2018-09-29 11:38:10
【问题描述】:
我正在使用 Laravel Hashing 的散列算法。
但出现此错误
未定义属性:Illuminate\Database\Eloquent\Builder::$password
这是我的功能
public function signin(LoginFormValidation $request)
{
$user_password = $request->password;
$data = User::where('email','=',$request->email);
if (Hash::check($user_password, $data->password, flase))
{
echo "success";
}
else
{
echo "still not";
}
}
【问题讨论】:
-
不是
flase是false,你应该使用first()或者get()