Backport IdentityLinker#failed? from GroupSaml callback flow
This commit is contained in:
parent
4bf47cd76f
commit
7425f2b322
2 changed files with 5 additions and 1 deletions
|
@ -82,7 +82,7 @@ class OmniauthCallbacksController < Devise::OmniauthCallbacksController
|
|||
|
||||
if identity_linker.changed?
|
||||
redirect_identity_linked
|
||||
elsif identity_linker.error_message.present?
|
||||
elsif identity_linker.failed?
|
||||
redirect_identity_link_failed(identity_linker.error_message)
|
||||
else
|
||||
redirect_identity_exists
|
||||
|
|
|
@ -17,6 +17,10 @@ module Gitlab
|
|||
@changed
|
||||
end
|
||||
|
||||
def failed?
|
||||
error_message.present?
|
||||
end
|
||||
|
||||
def error_message
|
||||
identity.validate
|
||||
|
||||
|
|
Loading…
Reference in a new issue