Commit e0d2b845 authored by ale's avatar ale
Browse files

Log LDAP errors

parent e259b416
...@@ -4,6 +4,7 @@ import ( ...@@ -4,6 +4,7 @@ import (
"context" "context"
"errors" "errors"
"io/ioutil" "io/ioutil"
"log"
"strings" "strings"
ldaputil "git.autistici.org/ai3/go-common/ldap" ldaputil "git.autistici.org/ai3/go-common/ldap"
...@@ -240,6 +241,7 @@ func (b *ldapBackend) GetUser(ctx context.Context, spec *BackendSpec, name strin ...@@ -240,6 +241,7 @@ func (b *ldapBackend) GetUser(ctx context.Context, spec *BackendSpec, name strin
result, err := b.pool.Search(ctx, serviceConfig.searchRequest(name)) result, err := b.pool.Search(ctx, serviceConfig.searchRequest(name))
if err != nil { if err != nil {
log.Printf("LDAP error: %v", err)
return nil, false return nil, false
} }
return serviceConfig.userFromResponse(name, result) return serviceConfig.userFromResponse(name, result)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment