Skip to content

Commit

Permalink
use Illuminate\Contracts\Auth\Authenticatable contract to get the use…
Browse files Browse the repository at this point in the history
…r password (#17965)

* changed from field access to getAuthPassword() method
  • Loading branch information
Jaime Sangcap authored and taylorotwell committed Feb 17, 2017
1 parent 48e6c09 commit 11d23b7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Illuminate/Session/Middleware/AuthenticateSession.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public function handle($request, Closure $next)
$this->storePasswordHashInSession($request);
}

if ($request->session()->get('password_hash') !== $request->user()->password) {
if ($request->session()->get('password_hash') !== $request->user()->getAuthPassword()) {
$this->logout($request);
}

Expand All @@ -69,7 +69,7 @@ protected function storePasswordHashInSession($request)
}

$request->session()->put([
'password_hash' => $request->user()->password,
'password_hash' => $request->user()->getAuthPassword(),
]);
}

Expand Down

0 comments on commit 11d23b7

Please sign in to comment.