--- issue: "025" title: "All dispute socket events are commented-out TODO stubs — no real-time updates in dispute flow" severity: major domain: dispute labels: [backend, missing-feature] status: open created: 2026-05-29 source: Doc vs Code Audit 2026-05-29 --- # 🟠 All dispute socket events are commented-out TODO stubs — no real-time updates in dispute flow **Severity:** major **Domain:** dispute **Labels:** backend, missing-feature ## Description Every `socket.io` emit block in `DisputeService` is currently commented out as a TODO. No real-time updates fire for any dispute lifecycle event: - Dispute created - Admin assigned - Status changed - Evidence uploaded - Resolution posted The dispute flow is CRUD-only. Any UI component that relies on socket events for real-time dispute state will never receive updates. ## Current Behavior All dispute state changes are only visible after a manual page refresh. ## Expected Behavior Implement the socket emit calls for key dispute events: - `dispute-created` → to buyer, seller, and admin rooms - `dispute-status-changed` → to involved parties - `dispute-resolved` → to buyer and seller rooms ## Affected Files - `backend/src/services/dispute/disputeService.ts` — all commented-out `io.to(...).emit(...)` blocks ## References - [Doc vs Code Audit Report](../09%20-%20Audits/Doc%20vs%20Code%20Audit%20Report%20-%202026-05-29.md)