Make Eloquent auth driver respect a model's custom password getter.

This fixes #1140.
This commit is contained in:
Franz Liedke 2012-09-04 16:36:17 +03:00
parent ec13efb743
commit 8e145e6c11
1 changed files with 1 additions and 1 deletions

View File

@ -50,7 +50,7 @@ public function attempt($arguments = array())
$password_field = Config::get('auth.password', 'password'); $password_field = Config::get('auth.password', 'password');
if ( ! is_null($user) and Hash::check($password, $user->get_attribute($password_field))) if ( ! is_null($user) and Hash::check($password, $user->{$password_field}))
{ {
return $this->login($user->id, array_get($arguments, 'remember')); return $this->login($user->id, array_get($arguments, 'remember'));
} }