Skip to content
Snippets Groups Projects
Commit eac56b61 authored by Jurnell Cockhren's avatar Jurnell Cockhren
Browse files

In the case when a user can and has authenticated with ldap, however

ldap is disabled in the gitlab config, this fixes the API still calling
the ldap backend.


Former-commit-id: e2e900a3
parent f778aec1
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -35,7 +35,9 @@ module API
user = key.user
 
return false if user.blocked?
return false if user.ldap_user? && Gitlab::LDAP::User.blocked?(user.extern_uid)
if Gitlab.config.ldap.enabled
return false if user.ldap_user? && Gitlab::LDAP::User.blocked?(user.extern_uid)
end
 
action = case git_cmd
when *DOWNLOAD_COMMANDS
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment