diff --git a/Web/public/404.html b/Web/public/404.html
index ed6bbee..dc6ce48 100644
--- a/Web/public/404.html
+++ b/Web/public/404.html
@@ -3,9 +3,164 @@
- Document
+ Echoes Behind Closed Doors
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
- 404
+
+
+
+

+

+
+
+
+
+
+
+
+
+
diff --git a/Web/public/js/ebcd-landing-qrcode.js b/Web/public/js/ebcd-landing-qrcode.js
index 019c2e9..686be70 100644
--- a/Web/public/js/ebcd-landing-qrcode.js
+++ b/Web/public/js/ebcd-landing-qrcode.js
@@ -51,6 +51,6 @@ function generateQrCode(text) {
);
}
-const svg = generateQrCode(window.location.origin + "/signup.html");
+const svg = generateQrCode(window.location.origin + "/auth.html");
document.getElementById("hero-svg").innerHTML = svg;
document.getElementById("hero-svg").classList.remove("uk-placeholder");
diff --git a/Web/public/js/ebcd-profile.js b/Web/public/js/ebcd-profile.js
index d1c946f..3cc8d21 100644
--- a/Web/public/js/ebcd-profile.js
+++ b/Web/public/js/ebcd-profile.js
@@ -10,9 +10,24 @@ if (urlParams.get("logOut") === "true") {
auth
.signOut()
.then(() => {
+ console.log("ebcd-profile: signed out");
window.location = "/";
})
.catch((error) => {
console.error("ebcd-profile: error signing out", error);
+ window.location = "/";
});
}
+
+// if we're signed in, reload the page with ?uid=...
+auth.onAuthStateChanged((user) => {
+ if (!urlParams.has("uid")) {
+ // if we dont have a uid and we're signed in, redirect to /profile?uid=...
+ if (user) {
+ window.location = `/profile.html?uid=${user.uid}`;
+ } else {
+ // if we're not signed in, redirect to 404
+ window.location = "/404.html";
+ }
+ }
+});