remotes/1693045480750635534/spooky-22
Aevann1 2021-11-23 23:03:20 +02:00
parent 584af0d620
commit 117f155ac0
2 changed files with 14 additions and 0 deletions

View File

@ -271,6 +271,13 @@ def sign_up_post(v):
email = request.values.get("email")
email = email.strip()
if email.endswith("@gmail.com"):
email=email.split('@')[0]
email=email.split('+')[0]
email=email.replace('.','')
email=f"{email}@gmail.com"
if not email: email = None
existing_account = get_user(username, graceful=True)

View File

@ -587,6 +587,13 @@ def settings_security_post(v):
escape("Invalid password."))
new_email = request.values.get("new_email","").strip()
if new_email.endswith("@gmail.com"):
new_email=new_email.split('@')[0]
new_email=new_email.split('+')[0]
new_email=new_email.replace('.','')
new_email=f"{new_email}@gmail.com"
if new_email == v.email:
return redirect("/settings/security?error=That email is already yours!")