From 7c08af0fb38ad3f06547b963e5bf89bce48ba8d6 Mon Sep 17 00:00:00 2001 From: enrilinux Date: Tue, 10 Mar 2026 18:14:21 +0100 Subject: [PATCH] eighth commit --- app/main.py | 4 ++++ app/templates/index.html | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/app/main.py b/app/main.py index 412932a..b9e2687 100644 --- a/app/main.py +++ b/app/main.py @@ -21,6 +21,10 @@ if not os.path.exists(HISTORY_FILE): with open(HISTORY_FILE, "w") as f: json.dump([], f) +def write_log(message): + with open(LOG_FILE, "a") as f: + f.write(f"{datetime.now().strftime('%H:%M:%S')} - {message}\n") + @app.get("/", response_class=HTMLResponse) async def home(request: Request): diff --git a/app/templates/index.html b/app/templates/index.html index d5a85ec..9b9dcb1 100644 --- a/app/templates/index.html +++ b/app/templates/index.html @@ -36,7 +36,7 @@ Download

History

-
+