Gregniuki commited on
Commit
9dfcf55
·
1 Parent(s): fe63148

Update auth.py

Browse files
Files changed (1) hide show
  1. auth.py +2 -1
auth.py CHANGED
@@ -1,4 +1,4 @@
1
- # app/routes/auth.py
2
  from fastapi import APIRouter, Depends, HTTPException, Form, Response, status, FastAPI
3
  from fastapi.security import OAuth2PasswordBearer, OAuth2PasswordRequestForm
4
  from fastapi.templating import Jinja2Templates
@@ -23,6 +23,7 @@ class AuthViews:
23
  class UserCreate(BaseModel):
24
  username: str
25
  password: str
 
26
 
27
  def register(self, user: UserCreate, db: Session = Depends(get_db)):
28
  # Validate email format and check for existing users
 
1
+ # app/auth.py
2
  from fastapi import APIRouter, Depends, HTTPException, Form, Response, status, FastAPI
3
  from fastapi.security import OAuth2PasswordBearer, OAuth2PasswordRequestForm
4
  from fastapi.templating import Jinja2Templates
 
23
  class UserCreate(BaseModel):
24
  username: str
25
  password: str
26
+ email: str
27
 
28
  def register(self, user: UserCreate, db: Session = Depends(get_db)):
29
  # Validate email format and check for existing users