MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / close

Function close

apps/kimi-web/src/composables/useTerminal.ts:80–90  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

78 }
79
80 async function close(): Promise<void> {
81 const current = terminal.value;
82 if (!current) return;
83 readOnly.value = true;
84 try {
85 ensureConnection()?.terminalClose(current.sessionId, current.id);
86 await getKimiWebApi().closeTerminal(current.sessionId, current.id);
87 } catch (error_) {
88 error.value = error_ instanceof Error ? error_.message : String(error_);
89 }
90 }
91
92 function restart(): void {
93 const current = terminal.value;

Callers

nothing calls this directly

Calls 4

getKimiWebApiFunction · 0.90
ensureConnectionFunction · 0.85
terminalCloseMethod · 0.65
closeTerminalMethod · 0.65

Tested by

no test coverage detected