(id: string, status: SessionStatus)
| 368 | }, |
| 369 | |
| 370 | updateSessionStatus(id: string, status: SessionStatus): Session | undefined { |
| 371 | const updatedAt = new Date().toISOString(); |
| 372 | const result = stmts.updateSessionStatus.run({ id, status, updatedAt }); |
| 373 | if (result.changes === 0) return undefined; |
| 374 | |
| 375 | const session = this.getSession(id); |
| 376 | if (session) { |
| 377 | const eventType: AFSEventType = status === "closed" ? "session.closed" : "session.updated"; |
| 378 | const event = eventBus.emit(eventType, id, session); |
| 379 | persistEvent(event); |
| 380 | } |
| 381 | return session; |
| 382 | }, |
| 383 | |
| 384 | listSessions(): Session[] { |
| 385 | const rows = stmts.listSessions.all() as Record<string, unknown>[]; |
nothing calls this directly
no test coverage detected
searching dependent graphs…