(id)
| 60 | |
| 61 | // Kill/remove a session |
| 62 | kill(id) { |
| 63 | if (!this.sessions.has(id)) return false; |
| 64 | this.sessions.delete(id); |
| 65 | if (this.activeId === id) { |
| 66 | // Switch to first remaining or null |
| 67 | const remaining = [...this.sessions.keys()]; |
| 68 | this.activeId = remaining[0] || null; |
| 69 | } |
| 70 | return true; |
| 71 | } |
| 72 | |
| 73 | // Get messages for the active session |
| 74 | getMessages() { |
no test coverage detected