summaryrefslogtreecommitdiffstats
path: root/apps/user_ldap
diff options
context:
space:
mode:
Diffstat (limited to 'apps/user_ldap')
-rw-r--r--apps/user_ldap/lib/connection.php7
1 files changed, 6 insertions, 1 deletions
diff --git a/apps/user_ldap/lib/connection.php b/apps/user_ldap/lib/connection.php
index 0372112f0e2..e5d9b4d5b40 100644
--- a/apps/user_ldap/lib/connection.php
+++ b/apps/user_ldap/lib/connection.php
@@ -80,7 +80,12 @@ class Connection {
public function __construct($configPrefix = '', $configID = 'user_ldap') {
$this->configPrefix = $configPrefix;
$this->configID = $configID;
- $this->cache = \OC_Cache::getGlobalCache();
+ $memcache = new \OC\Memcache\Factory();
+ if($memcache->isAvailable()) {
+ $this->cache = $memcache->create();
+ } else {
+ $this->cache = \OC_Cache::getGlobalCache();
+ }
$this->config['hasPagedResultSupport'] = (function_exists('ldap_control_paged_result')
&& function_exists('ldap_control_paged_result_response'));
}