Skip to content
This repository was archived by the owner on Jul 24, 2023. It is now read-only.

Commit fb73e7d

Browse files
committed
Added comments.
1 parent eab6380 commit fb73e7d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Middleware/WindowsAuthenticate.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,12 +65,16 @@ public function handle(Request $request, Closure $next)
6565
->whereEquals($key, $username)
6666
->first();
6767

68+
// Double check that we have the correct AD user instance.
6869
if ($user instanceof User) {
70+
// Retrieve the Eloquent user model from our AD user instance.
6971
$model = $this->getModelFromAdldap($user, str_random());
7072

7173
if ($model instanceof Model) {
74+
// If we've been given the correct object instance, we'll log the user in.
7275
$this->auth->login($model);
7376

77+
// Perform any further operations on the authenticated user model.
7478
$this->handleAuthenticatedUser($model);
7579
}
7680
}

0 commit comments

Comments
 (0)