From 72c69c3d429910a0fbfb4696fda6b0993e9070e8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20Gruszczy=C5=84ski?= Date: Thu, 9 Oct 2025 17:00:29 +0200 Subject: [PATCH] dane w headerach i inne funkcje --- app/main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/main.py b/app/main.py index 13086c2..f7af6d6 100644 --- a/app/main.py +++ b/app/main.py @@ -44,9 +44,9 @@ async def root(request: Request): ip = get_client_ip(request).strip() if any(x in ua for x in ["mozilla", "chrome", "safari", "edge", "firefox"]): - return Response(status_code=404) + return JSONResponse({"detail": "Not Found"}, status_code=404) - return PlainTextResponse(ip) + return PlainTextResponse(ip + "\n") if __name__ == "__main__":