mirror of
https://gitlab.com/davical-project/davical.git
synced 2026-05-27 02:54:27 +00:00
Instance caching added
There was already a variable to cache the ldap driver instance, and a check if this variable was already set was there, too! But there was no code to return the cached instance if the function gets called twice! Maybe this was simply forgotten...
This commit is contained in:
parent
f3b67a2c62
commit
40c87435c1
@ -254,6 +254,10 @@ function getStaticLdap() {
|
||||
// If the instance is not there, create one
|
||||
if(!isset($instance)) {
|
||||
$ldapDrivers = new ldapDrivers($c->authenticate_hook['config']);
|
||||
$instance = $ldapDrivers
|
||||
}
|
||||
else {
|
||||
$ldapDrivers = $instance
|
||||
}
|
||||
return $ldapDrivers;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user