diff --git a/kinode/src/http/login.html b/kinode/src/http/login.html index 0e5481b54..6d197345f 100644 --- a/kinode/src/http/login.html +++ b/kinode/src/http/login.html @@ -177,9 +177,10 @@

Logging in...

document.getElementById("login-button").disabled = false; isInitialized = true; + return [isSecureSubdomain, firstPathItem]; } - async function login(password) { + async function login(password, isSecureSubdomain, firstPathItem) { document.getElementById("login-form").style.display = "none"; document.getElementById("loading").style.display = "flex"; @@ -219,18 +220,18 @@

Logging in...

} document.addEventListener("DOMContentLoaded", () => { - initializeLoginForm(); + const [isSecureSubdomain, firstPathItem] = initializeLoginForm(); const form = document.getElementById("login-form"); form.addEventListener("submit", (e) => { e.preventDefault(); e.stopPropagation(); if (isInitialized) { const password = document.getElementById("password").value; - login(password); + login(password, isSecureSubdomain, firstPathItem); } }); }); - \ No newline at end of file +