Bladeren bron

passsword mod3

main
Madiwka3 1 jaar geleden
bovenliggende
commit
6719031fef
1 gewijzigde bestanden met toevoegingen van 2 en 2 verwijderingen
  1. +2
    -2
      app/apis/v1/route_user.py

+ 2
- 2
app/apis/v1/route_user.py Bestand weergeven

@@ -91,8 +91,8 @@ def update_user(
db: Session = Depends(get_db),
current_user: User = Depends(get_current_user),
):
if current_user.Role != "Admin" and current_user.id != user_id:
print(current_user.Role, current_user.id, user_id)
if current_user.Role != "Admin" and current_user.Id != user_id:
print(current_user.Role, current_user.Id, user_id)
raise HTTPException(
status_code=403, detail="You are not authorized to perform this action"
)


Laden…
Annuleren
Opslaan