diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-02-17 09:26:10 +0200 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-02-17 09:26:10 +0200 |
commit | 0744eac9c61efcba998a5328acf01f80bdfa6e84 (patch) | |
tree | 132ebe350092b74af04b2f1bac91047fd96759f7 /lib/api | |
parent | 8136048875004a21632e98eaa6d675a529caa831 (diff) | |
parent | e2e900a338894010e7ba4dac89fa7b926803a977 (diff) | |
download | gitlab-ce-0744eac9c61efcba998a5328acf01f80bdfa6e84.tar.gz |
Merge pull request #6189 from jcockhren/api_ldap_check_for_user
the existence of former ldap users doesn't imply LDAP is enabled.
Diffstat (limited to 'lib/api')
-rw-r--r-- | lib/api/internal.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/api/internal.rb b/lib/api/internal.rb index ed6b50c3a6a..ebc9fef07b4 100644 --- a/lib/api/internal.rb +++ b/lib/api/internal.rb @@ -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 |