From b314815df1765edde247682e4b8475a3ba5abea6 Mon Sep 17 00:00:00 2001 From: Guillaume Chervet <52236059+guillaume-chervet@users.noreply.github.com> Date: Tue, 1 Mar 2022 15:29:13 +0100 Subject: [PATCH] fix(demo): url in dynamic instead of hard coded (#707) --- packages/context/src/MultiAuth.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/context/src/MultiAuth.tsx b/packages/context/src/MultiAuth.tsx index ab550efd0..705cf7a19 100644 --- a/packages/context/src/MultiAuth.tsx +++ b/packages/context/src/MultiAuth.tsx @@ -31,10 +31,10 @@ if(!sessionStorage.configurationName){ export const MultiAuthContainer = () => { const [configurationName, setConfigurationName] = useState(sessionStorage.configurationName); - const callBack = "http://localhost:4200/multi-auth/authentification/callback2"; + const callBack = window.location.origin+"/multi-auth/authentification/callback2"; const configurations = { "config_1": {...configurationIdentityServer, redirect_uri:callBack}, - "config_2": {...configurationIdentityServer, redirect_uri:callBack, scope: 'openid profile email api',} + "config_2": {...configurationIdentityServer, redirect_uri:callBack, scope: 'openid profile email api'} } const handleConfigurationChange = (event) => { const configurationName = event.target.value;