diff options
Diffstat (limited to 'src/main.js')
-rw-r--r-- | src/main.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main.js b/src/main.js index 6f5b02a..e6d9264 100644 --- a/src/main.js +++ b/src/main.js @@ -51,11 +51,12 @@ async function register() { const username = document.getElementById("username").value; const password = document.getElementById("password").value; const id = document.getElementById("id").value; + const key = document.getElementById("key").value; const url = server + "/user/register/" - var body = {"name": username, "password": password, "id": id}; + var body = {"name": username, "password": password, "id": id, "key": key}; if (id == "") { - body = {"name": username, "password": password} + body = {"name": username, "password": password, "key": key} } const req = await xhttp_post(url, body); @@ -312,7 +313,6 @@ async function update_name_form() { window.onload = async function() { // if not on a user page if (window.location.pathname.indexOf("/user") == -1) { - console.log("NOT A USER PAGE") // and if logged in if (await is_logged_in()) { // move to the user index page |