Skip to content

Commit

Permalink
Implement hasUser()
Browse files Browse the repository at this point in the history
  • Loading branch information
Robson Tenório authored and Robson Tenório committed Oct 27, 2018
1 parent 0b51d03 commit 3ffcf27
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/KeycloakGuard.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,16 @@ public function check()
return !is_null($this->user());
}

/**
* Determine if the guard has a user instance.
*
* @return bool
*/
public function hasUser()
{
return !is_null($this->user());
}

/**
* Determine if the current user is a guest.
*
Expand Down

0 comments on commit 3ffcf27

Please sign in to comment.