This commit is contained in:
2024-06-15 22:37:29 +03:00

View File

@ -175,7 +175,7 @@ def patch_anon_name(
def get_captcha( def get_captcha(
captcha_id: uuid.UUID, db: Annotated[Session, Depends(get_db)] captcha_id: uuid.UUID, db: Annotated[Session, Depends(get_db)]
) -> BytesIO: ) -> BytesIO:
prompt = "".join(random.choice(CAPTCHA_SYMBOLS) for i in range(6)) prompt = "".join(random.choice(CAPTCHA_SYMBOLS) for i in range(4))
c = models.Captcha(id=captcha_id, prompt=prompt) c = models.Captcha(id=captcha_id, prompt=prompt)
try: try:
db.add(c) db.add(c)