Commit 198ba5a0 authored by Nick Thomas's avatar Nick Thomas

Merge branch 'ce-jej/group-saml-sso-when-signed-out' into 'master'

[CE] Backport build_auth_user for GroupSAML callback

See merge request gitlab-org/gitlab-ce!24979
parents d91b9645 24f3f960
...@@ -116,8 +116,12 @@ class OmniauthCallbacksController < Devise::OmniauthCallbacksController ...@@ -116,8 +116,12 @@ class OmniauthCallbacksController < Devise::OmniauthCallbacksController
session[:service_tickets][provider] = ticket session[:service_tickets][provider] = ticket
end end
def build_auth_user(auth_user_class)
auth_user_class.new(oauth)
end
def sign_in_user_flow(auth_user_class) def sign_in_user_flow(auth_user_class)
auth_user = auth_user_class.new(oauth) auth_user = build_auth_user(auth_user_class)
user = auth_user.find_and_update! user = auth_user.find_and_update!
if auth_user.valid_sign_in? if auth_user.valid_sign_in?
......
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