From 770c3e4df69a13517781049df168a1860120bc58 Mon Sep 17 00:00:00 2001 From: Backend IM Bot Date: Sat, 29 Mar 2025 20:55:35 +0000 Subject: [PATCH] Update code in endpoints/signup.post.py --- endpoints/signup.post.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/endpoints/signup.post.py b/endpoints/signup.post.py index 9bed033..ba0d5da 100644 --- a/endpoints/signup.post.py +++ b/endpoints/signup.post.py @@ -7,12 +7,12 @@ from helpers.auth_helpers import authenticate_user, create_access_token router = APIRouter() -@router.post("/login", response_model=UserResponse) +@router.post("/signup", status_code=status.HTTP_201_CREATED, response_model=UserResponse) async def login( - user_credentials: UserLogin, + user_data: UserLogin, db: Session = Depends(get_db) ): - user = authenticate_user(db, user_credentials.email, user_credentials.password) + user = authenticate_user(db, user_data.email, user_data.password) if not user: raise HTTPException( status_code=status.HTTP_401_UNAUTHORIZED,