Stopped login code from falling back to LDAP when it's disabled (#2986)

This commit is contained in:
Harrison Healey
2016-05-12 21:36:02 -04:00
committed by Corey Hulen
parent 94f8be51f9
commit 4f22cbc92b
2 changed files with 2 additions and 2 deletions

View File

@@ -127,7 +127,7 @@ func checkUserNotDisabled(user *model.User) *model.AppError {
}
func authenticateUser(user *model.User, password, mfaToken string) (*model.User, *model.AppError) {
ldapAvailable := *utils.Cfg.LdapSettings.Enable && einterfaces.GetLdapInterface() != nil
ldapAvailable := *utils.Cfg.LdapSettings.Enable && einterfaces.GetLdapInterface() != nil && utils.IsLicensed && *utils.License.Features.LDAP
if user.AuthService == model.USER_AUTH_SERVICE_LDAP {
if !ldapAvailable {