diff --git a/apps/user_ldap/lib/Group_LDAP.php b/apps/user_ldap/lib/Group_LDAP.php index 93320b3166920..137167b1c1adc 100644 --- a/apps/user_ldap/lib/Group_LDAP.php +++ b/apps/user_ldap/lib/Group_LDAP.php @@ -944,8 +944,8 @@ public function usersInGroup($gid, $search = '', $limit = -1, $offset = 0) { break; } - $cacheKey = 'userExistsOnLDAP' . $uid; - $userExists = $this->access->connection->getFromCache($cacheKey); + $userExistsCacheKey = 'userExistsOnLDAP' . $uid; + $userExists = $this->access->connection->getFromCache($userExistsCacheKey); if ($userExists === false) { break; } @@ -957,11 +957,11 @@ public function usersInGroup($gid, $search = '', $limit = -1, $offset = 0) { $this->access->connection->ldapUserFilter ]))) { if ($search === '') { - $this->access->connection->writeToCache($cacheKey, false); + $this->access->connection->writeToCache($userExistsCacheKey, false); } break; } - $this->access->connection->writeToCache($cacheKey, true); + $this->access->connection->writeToCache($userExistsCacheKey, true); } $groupUsers[] = $uid; break;