From d76f63723f2a228993d9ae41784db0671b14213a Mon Sep 17 00:00:00 2001 From: trinkey <97406176+trinkey@users.noreply.github.com> Date: Tue, 20 Feb 2024 19:09:45 -0500 Subject: [PATCH] fix casing and add readme --- README.md | 8 ++++++++ _server.py | 10 ++-------- 2 files changed, 10 insertions(+), 8 deletions(-) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..8bd39ea --- /dev/null +++ b/README.md @@ -0,0 +1,8 @@ +# infopage +or https://infpg.pythonanywhere.com + +it's like pronouns.page but i made it + +### todo +* social links +* sexuality/gender flags diff --git a/_server.py b/_server.py index e722d18..0bbed93 100644 --- a/_server.py +++ b/_server.py @@ -118,7 +118,7 @@ def api_account_login(): def api_account_signup(): try: x = json.loads(request.data) - username = x["username"].replace(" ", "") + username = x["username"].replace(" ", "").lower() passhash = x["password"] except json.JSONDecodeError: flask.abort(400) @@ -163,7 +163,7 @@ def api_account_signup(): "background": "#111122" }, "names": [ - [username, "4"] + [x["username"], "4"] ], "pronouns": [ ["he/him", "3"], @@ -293,12 +293,6 @@ def api_save(): def u_(username): return flask.send_file(f"{CONTENT_DIRECTORY}user.html") -# levels: -# 4 - love -# 3 - good -# 2 - okay -# 1 - bad - ensure_file(SAVING_DIRECTORY, folder=True) ensure_file(f"{SAVING_DIRECTORY}tokens/", folder=True)