Ali2206 commited on
Commit
33cb388
·
verified ·
1 Parent(s): be94b8c

Update api/routes.py

Browse files
Files changed (1) hide show
  1. api/routes.py +2 -1
api/routes.py CHANGED
@@ -13,10 +13,11 @@ async def signup(data: SignupForm):
13
  existing = await users_collection.find_one({"email": email})
14
  if existing:
15
  raise HTTPException(status_code=409, detail="Email already exists")
16
-
17
  hashed_pw = hash_password(data.password)
18
  user_doc = {
19
  "email": email,
 
20
  "password": hashed_pw,
21
  "created_at": datetime.utcnow()
22
  }
 
13
  existing = await users_collection.find_one({"email": email})
14
  if existing:
15
  raise HTTPException(status_code=409, detail="Email already exists")
16
+
17
  hashed_pw = hash_password(data.password)
18
  user_doc = {
19
  "email": email,
20
+ "full_name": data.full_name.strip(),
21
  "password": hashed_pw,
22
  "created_at": datetime.utcnow()
23
  }