fix(api): re-use previous password when ldap settings update use empty password (#2659)

pull/2634/merge
Anthony Lapenna 6 years ago committed by GitHub
parent 801336336f
commit fca4f619b5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -66,7 +66,12 @@ func (handler *Handler) settingsUpdate(w http.ResponseWriter, r *http.Request) *
}
if payload.LDAPSettings != nil {
ldapPassword := settings.LDAPSettings.Password
if payload.LDAPSettings.Password != "" {
ldapPassword = payload.LDAPSettings.Password
}
settings.LDAPSettings = *payload.LDAPSettings
settings.LDAPSettings.Password = ldapPassword
}
if payload.AllowBindMountsForRegularUsers != nil {

Loading…
Cancel
Save