diff --git a/app/user_service.py b/app/user_service.py index 10a8f93..f543429 100644 --- a/app/user_service.py +++ b/app/user_service.py @@ -82,6 +82,7 @@ def get_user_by_id(user_id: str): """, {"user_id": user_id} ) + if not result or len(result) == 0: raise HTTPException(status_code=404, detail="User not found") return result[0]