From 75ac77dea8d94960f7942a37c63ba2d06f5588cf Mon Sep 17 00:00:00 2001 From: csd4ni3l Date: Sat, 9 Aug 2025 12:45:46 +0200 Subject: [PATCH] make the password a password field and add username when uploading the file --- templates/login.jinja2 | 2 +- templates/register.jinja2 | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/templates/login.jinja2 b/templates/login.jinja2 index 42b454d..eeb12cc 100644 --- a/templates/login.jinja2 +++ b/templates/login.jinja2 @@ -13,7 +13,7 @@
- +
diff --git a/templates/register.jinja2 b/templates/register.jinja2 index 75a5061..51a3fdb 100644 --- a/templates/register.jinja2 +++ b/templates/register.jinja2 @@ -13,7 +13,7 @@
- +
@@ -51,9 +51,10 @@ function upload_error(error_message) { } function upload_file(file_type, file_content) { + username_input = document.getElementById("usernameinput").value fetch('{{ url_for("upload") }}', { method: "POST", - body: JSON.stringify({image_data: file_content, image_type: file_type}), + body: JSON.stringify({image_data: file_content, image_type: file_type, username: username_input}), headers: { "Content-type": "application/json" }