LDAP: use memcache if available

remotes/origin/stable6
Arthur Schiwon 12 years ago
parent c538ac3081
commit f41c4312ff
  1. 5
      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;
$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'));
}

Loading…
Cancel
Save