sign_out all devise account when user initialize a FranceConnect connection
This commit is contained in:
parent
008ca19bef
commit
c461d58297
1 changed files with 5 additions and 0 deletions
|
@ -1,4 +1,5 @@
|
||||||
class FranceConnect::ParticulierController < ApplicationController
|
class FranceConnect::ParticulierController < ApplicationController
|
||||||
|
|
||||||
def login
|
def login
|
||||||
client = FranceConnectParticulierClient.new
|
client = FranceConnectParticulierClient.new
|
||||||
|
|
||||||
|
@ -94,6 +95,10 @@ class FranceConnect::ParticulierController < ApplicationController
|
||||||
private
|
private
|
||||||
|
|
||||||
def connect_france_connect_particulier user
|
def connect_france_connect_particulier user
|
||||||
|
sign_out :user if user_signed_in?
|
||||||
|
sign_out :gestionnaire if gestionnaire_signed_in?
|
||||||
|
sign_out :administrateur if administrateur_signed_in?
|
||||||
|
|
||||||
sign_in user
|
sign_in user
|
||||||
|
|
||||||
user.loged_in_with_france_connect = 'particulier'
|
user.loged_in_with_france_connect = 'particulier'
|
||||||
|
|
Loading…
Reference in a new issue