diff options
author | Rémy Coutable <remy@rymai.me> | 2018-05-18 14:19:20 +0300 |
---|---|---|
committer | Rémy Coutable <remy@rymai.me> | 2018-05-18 17:30:53 +0300 |
commit | 37cd2b9b4dcf4c0145fd1bc2e19c8e903b4fd4fa (patch) | |
tree | cada3fd1a3547faed2601ce53f4d75418104e9b7 /lib/gitlab/auth/saml/user.rb | |
parent | 0a581fcfa28696245be297da39b12207a8ae0255 (diff) |
Minimize CE/EE difference in Gitlab::Auth::Saml::User
Signed-off-by: Rémy Coutable <remy@rymai.me>
Diffstat (limited to 'lib/gitlab/auth/saml/user.rb')
-rw-r--r-- | lib/gitlab/auth/saml/user.rb | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/gitlab/auth/saml/user.rb b/lib/gitlab/auth/saml/user.rb index cb01cd8004c..b8c84c37cd5 100644 --- a/lib/gitlab/auth/saml/user.rb +++ b/lib/gitlab/auth/saml/user.rb @@ -20,10 +20,8 @@ module Gitlab user ||= find_or_build_ldap_user if auto_link_ldap_user? user ||= build_new_user if signup_enabled? - if external_users_enabled? && user - # Check if there is overlap between the user's groups and the external groups - # setting then set user as external or internal. - user.external = !(auth_hash.groups & saml_config.external_groups).empty? + if user + user.external = !(auth_hash.groups & saml_config.external_groups).empty? if external_users_enabled? end user |