Update app.py
Browse files
app.py
CHANGED
@@ -425,7 +425,8 @@ def register_user(user_data: UserCreate, db: Session):
|
|
425 |
async def get_protected(
|
426 |
request: Request,
|
427 |
db: Session = Depends(get_db),
|
428 |
-
authorization: Optional[str] = Header(None)
|
|
|
429 |
):
|
430 |
# Try to get the token from the Authorization header
|
431 |
if authorization:
|
|
|
425 |
async def get_protected(
|
426 |
request: Request,
|
427 |
db: Session = Depends(get_db),
|
428 |
+
authorization: Optional[str] = Header(None),# token from Authorization header
|
429 |
+
token: Optional[str] = None
|
430 |
):
|
431 |
# Try to get the token from the Authorization header
|
432 |
if authorization:
|