mirror of
https://gitlab.com/davical-project/davical.git
synced 2026-08-31 18:46:02 +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
72dc5b1f39
commit
953b922a13
@ -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