MCPcopy Create free account
hub / github.com/apptools-lab/AppToolkit / killChannelChildProcess

Function killChannelChildProcess

main/utils/killChannelChildProcess.ts:3–13  ·  view source on GitHub ↗
(
  channelChildProcessMap: Map<string, child_process.ChildProcess>,
  channel: string,
)

Source from the content-addressed store, hash-verified

1import * as child_process from 'child_process';
2
3function killChannelChildProcess(
4 channelChildProcessMap: Map<string, child_process.ChildProcess>,
5 channel: string,
6) {
7 const childProcess = channelChildProcessMap.get(channel);
8 if (childProcess && childProcess.kill instanceof Function) {
9 // kill child process
10 childProcess.kill();
11 channelChildProcessMap.delete(channel);
12 }
13}
14
15export default killChannelChildProcess;

Callers 5

handleApp.tsFile · 0.85
installNode.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected