diff --git a/.gitignore b/.gitignore index a20d87b6..d102693a 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,4 @@ composer.lock Modules/ build +/nbproject/private/ \ No newline at end of file diff --git a/Repositories/Sentinel/SentinelAuthentication.php b/Repositories/Sentinel/SentinelAuthentication.php index b436b52f..bd2bd98d 100644 --- a/Repositories/Sentinel/SentinelAuthentication.php +++ b/Repositories/Sentinel/SentinelAuthentication.php @@ -125,7 +125,7 @@ public function completeResetPassword($user, $code, $password) */ public function hasAccess($permission) { - if (! Sentinel::check()) { + if (Sentinel::guest()) { return false; } @@ -138,9 +138,8 @@ public function hasAccess($permission) */ public function check() { - $user = Sentinel::check(); - - if ($user) { + + if (! Sentinel::guest()) { return true; }