Commit ac07c066 authored by James Lopez's avatar James Lopez

Add saml provider to user build service

parent ff648879
......@@ -26,7 +26,7 @@ module Users
end
end
identity_attrs = params.slice(:extern_uid, :provider)
identity_attrs = params.slice(*identity_params)
unless identity_attrs.empty?
user.identities.build(identity_attrs)
......@@ -37,6 +37,10 @@ module Users
private
def identity_params
[:extern_uid, :provider]
end
def can_create_user?
(current_user.nil? && Gitlab::CurrentSettings.allow_signup?) || current_user&.admin?
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment