Skip to content

Commit

Permalink
fix(frontend): fix request display
Browse files Browse the repository at this point in the history
  • Loading branch information
Björn Urban committed Apr 11, 2024
1 parent 47ca00d commit 10ea658
Showing 1 changed file with 2 additions and 11 deletions.
13 changes: 2 additions & 11 deletions frontend/Request.svelte
Original file line number Diff line number Diff line change
@@ -1,16 +1,7 @@
<script>
import { onMount } from 'svelte';
let redirectURL = '';
function getCookie(name) {
let cookieArray = document.cookie.split(';');
for (let i = 0; i < cookieArray.length; i++) {
let cookiePair = cookieArray[i].split('=');
if (name === cookiePair[0].trim()) {
return decodeURIComponent(cookiePair[1]);
}
}
return null;
}
onMount(() => {
// Extract the redirect URL from the query parameters
Expand All @@ -37,6 +28,6 @@

<div class="container mt-5">
<h3>Request Access</h3>
<p>You are trying to access: <strong>{getCookie('X-Auth-Site')}</strong></p>
<p>You are trying to access: <strong>{redirectURL}</strong></p>
<button class="btn btn-primary" on:click={requestAccess}>Request Access</button>
</div>

0 comments on commit 10ea658

Please sign in to comment.