Simplify code (#5452)
https://github.com/mattermost/platform/blob/master/app/authentication.go#L149 has compared `user.AuthService` with `model.USER_AUTH_SERVICE_LDAP`, so this check is useless here.
Этот коммит содержится в:
коммит произвёл
George Goldberg
родитель
b3afe9fb16
Коммит
c817c5d740
@@ -160,7 +160,7 @@ func authenticateUser(user *model.User, password, mfaToken string) (*model.User,
|
|||||||
}
|
}
|
||||||
} else if user.AuthService != "" {
|
} else if user.AuthService != "" {
|
||||||
authService := user.AuthService
|
authService := user.AuthService
|
||||||
if authService == model.USER_AUTH_SERVICE_SAML || authService == model.USER_AUTH_SERVICE_LDAP {
|
if authService == model.USER_AUTH_SERVICE_SAML {
|
||||||
authService = strings.ToUpper(authService)
|
authService = strings.ToUpper(authService)
|
||||||
}
|
}
|
||||||
err := model.NewLocAppError("login", "api.user.login.use_auth_service.app_error", map[string]interface{}{"AuthService": authService}, "")
|
err := model.NewLocAppError("login", "api.user.login.use_auth_service.app_error", map[string]interface{}{"AuthService": authService}, "")
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user