summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/Auth/LDAP.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/Auth/LDAP.php b/lib/Auth/LDAP.php
index d4b0fd9..262768c 100644
--- a/lib/Auth/LDAP.php
+++ b/lib/Auth/LDAP.php
@@ -43,7 +43,7 @@ class LDAP extends Net_LDAP3 {
// Causes nesting levels to be too deep...?
//$this->config_set('config_get_hook', array($this, "_config_get"));
- $this->config_set("debug", true);
+ $this->config_set("debug", Log::mode() == Log::TRACE);
$this->config_set("log_hook", array($this, "_log"));
$this->config_set("config_root_dn", "cn=config");
@@ -1172,6 +1172,9 @@ class LDAP extends Net_LDAP3 {
Log::debug($str . $msg);
break;
case LOG_ERR:
+ case LOG_ALERT:
+ case LOG_CRIT:
+ case LOG_EMERG:
Log::error($str . $msg);
break;
case LOG_INFO:
@@ -1180,9 +1183,6 @@ class LDAP extends Net_LDAP3 {
case LOG_WARNING:
Log::warning($str . $msg);
break;
- case LOG_ALERT:
- case LOG_CRIT:
- case LOG_EMERG:
case LOG_NOTICE:
default:
Log::trace($str . $msg);