Minor modifications

This commit is contained in:
Mattia Giambirtone 2022-10-05 18:00:35 +02:00
parent 185ca3f354
commit f0ef827577
2 changed files with 5 additions and 5 deletions

View File

@ -71,7 +71,7 @@ VALIDATE_USERNAME_REGEX = (
# - At least 2 numbers
# You can change the repetitions to enforce stricter/laxer rules or empty
# this field to disable weakness validation
VALIDATE_PASSWORD_REGEX = r"^(?=.*[A-Z]){2,}(?=.*[!@%#$&*_^\?\\\/(\)\+\-])+(?=.*[0-9]){2,}(?=.*[a-z]){3,}.{10,72}$"
VALIDATE_PASSWORD_REGEX = r"^(?=.*[A-Z]){2,}(?=.*[\"!@%#$&*_^\?\\\/(\)\+\-])+(?=.*[0-9]){2,}(?=.*[a-z]){3,}.{10,72}$"
FORCE_EMAIL_VERIFICATION = False
EMAIL_VERIFICATION_EXPIRATION = 3600 # In seconds
PLATFORM_NAME = "PySimpleSocial" # Used in emails

View File

@ -296,10 +296,10 @@ async def get_user_by_public_id(
async def validate_user(
first_name: str,
last_name: str,
username: str,
email: str,
first_name: str | None,
last_name: str | None,
username: str | None,
email: str | None,
password: str | None,
bio: str | None,
) -> tuple[bool, str]: