Commit c1632ea0 authored by ale's avatar ale
Browse files

Fix compile error

parent 01a58c48
......@@ -205,8 +205,11 @@ func newLDAPBackend(config *Config) (*ldapBackend, error) {
}
// Read the bind password.
bindPw := config.LDAPConfig.BindPw
if bindPw == "" {
var bindPw []byte
if config.LDAPConfig.BindPw != "" {
bindPw = []byte(config.LDAPConfig.BindPw)
} else {
var err error
bindPw, err = ioutil.ReadFile(config.LDAPConfig.BindPwFile)
if err != nil {
return nil, err
......
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