瀏覽代碼

passsword mod3

main
Madiwka3 1 年之前
父節點
當前提交
9b9dcd91b0
共有 1 個檔案被更改,包括 1 行新增1 行删除
  1. +1
    -1
      app/apis/v1/route_user.py

+ 1
- 1
app/apis/v1/route_user.py 查看文件

@@ -91,7 +91,7 @@ def update_user(
db: Session = Depends(get_db),
current_user: User = Depends(get_current_user),
):
if current_user.Role != "Admin" or 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"


Loading…
取消
儲存