diff --git a/B01_Dashboard/B01_Dashboard_Repository.py b/B01_Dashboard/B01_Dashboard_Repository.py index 9a3976f3..25fee587 100644 --- a/B01_Dashboard/B01_Dashboard_Repository.py +++ b/B01_Dashboard/B01_Dashboard_Repository.py @@ -287,7 +287,14 @@ async def update_project(project_id: str, data: dict[str, Any], actor_id: int) - ), ) changed = cursor.rowcount > 0 - if changed: + if not changed: + # 값이 하나도 안 바뀌면 rowcount 가 0 이다 — 프로젝트가 없는 것과는 다르다 + # (참여자만 바꿀 때 「찾을 수 없습니다」로 튕기던 자리, 2026-09-06). + await cursor.execute( + "SELECT 1 FROM projects WHERE id = %s AND deleted_at IS NULL", (project_id,) + ) + changed = await cursor.fetchone() is not None + else: await cursor.execute( """INSERT INTO system_audit_logs (user_id, action, resource_type, resource_id) VALUES (%s, 'PROJECT_UPDATE', 'project', NULL)""",