|
|
|
@ -23,7 +23,7 @@ def get_current_username(credentials: HTTPBasicCredentials = Depends(security)): |
|
|
|
raise HTTPException( |
|
|
|
status_code=status.HTTP_401_UNAUTHORIZED, |
|
|
|
detail="Incorrect username or password", |
|
|
|
headers={"WWW-Authenticate": "Basic"}, |
|
|
|
headers=security.make_authenticate_headers(), |
|
|
|
) |
|
|
|
return credentials.username |
|
|
|
|
|
|
|
|