diff --git a/src/AuthMiddleware.php b/src/AuthMiddleware.php
index <HASH>..<HASH> 100644
--- a/src/AuthMiddleware.php
+++ b/src/AuthMiddleware.php
@@ -25,7 +25,6 @@ class AuthMiddleware
         $auth->setRequest($req)->setResponse($res);
 
         $user = $auth->getAuthenticatedUser();
-        $this->app['user'] = $user;
 
         // use the authenticated user as the requester for model permissions
         ACLModel::setRequester($user);
diff --git a/src/Libs/Auth.php b/src/Libs/Auth.php
index <HASH>..<HASH> 100644
--- a/src/Libs/Auth.php
+++ b/src/Libs/Auth.php
@@ -249,9 +249,11 @@ class Auth
 
         // if no current user then sign in a guest
         if (!$user) {
-            return $this->signInUser($this->getGuestUser());
+            $user = $this->signInUser($this->getGuestUser());
         }
 
+        $this->app['user'] = $user;
+
         return $user;
     }
set user on DI container in getAuthenticatedUser()