fix(ds-fr/fc-secrets): Patch only the secrets.yml file

This commit is contained in:
Tom Hubrecht 2023-09-26 08:34:43 +02:00
parent 64d186238c
commit 156310fdce

View file

@ -17,23 +17,3 @@ index 866fa6159..6fd49ee59 100644
agent_connect: agent_connect:
identifier: <%= ENV['AGENT_CONNECT_ID'] %> identifier: <%= ENV['AGENT_CONNECT_ID'] %>
secret: <%= ENV['AGENT_CONNECT_SECRET'] %> secret: <%= ENV['AGENT_CONNECT_SECRET'] %>
diff --git a/app/services/france_connect_service.rb b/app/services/france_connect_service.rb
index 31b2491c4..fd3d80530 100644
--- a/app/services/france_connect_service.rb
+++ b/app/services/france_connect_service.rb
@@ -23,11 +23,15 @@ class FranceConnectService
def self.retrieve_user_informations_particulier(code)
client = FranceConnectParticulierClient.new(code)
+ Rails.logger.fatal("Client: #{client.inspect}")
+ Rails.logger.fatal("Client token: #{client.access_token!(client_auth_method: :secret).userinfo!.inspect}")
user_info = client.access_token!(client_auth_method: :secret)
.userinfo!
.raw_attributes
+ Rails.logger.fatal("Info: #{user_info.inspect}")
+
FranceConnectInformation.new(
gender: user_info[:gender],
given_name: user_info[:given_name],