diff --git a/frontend/src/Components/Login.svelte b/frontend/src/Components/Login.svelte index c0e86b2..61a55d4 100644 --- a/frontend/src/Components/Login.svelte +++ b/frontend/src/Components/Login.svelte @@ -36,7 +36,9 @@ } - async function redirectTo(service){ + async function redirectTo(e,service){ + const btn = e.target; + btn.disabled = true; const url = api(`user/oidc/redirect/${service}`); const resp = await fetch(url,{credentials:'include'}); if (resp.ok){ @@ -46,6 +48,9 @@ delete json.authorization_endpoint; location.href = endpoint + '?' + new URLSearchParams(json); } + } else { + error = resp.text(); + btn.disabled = false; } } @@ -100,6 +105,6 @@
{t('oidc_Login')} {#each services as service,i} - + {/each}