From c25bcbef84bd2f4f259e754ee94d74b55a88dbb2 Mon Sep 17 00:00:00 2001 From: Nathan Woodburn Date: Fri, 21 Jun 2024 18:01:06 +1000 Subject: [PATCH] fix: Normalize username before getting pfp --- website/routes.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/website/routes.py b/website/routes.py index c60dfa9..a440cc8 100644 --- a/website/routes.py +++ b/website/routes.py @@ -601,6 +601,8 @@ def profile(username): @bp.route("/u//avatar.png") def avatar(username): + username = username.lower().strip().replace("/", "") + user = User.query.filter_by(username=username).first() if not user: print("User not found")