MCPcopy Create free account
hub / github.com/scriptscat/scriptcat / disableScript

Method disableScript

src/app/service/sandbox/runtime.ts:115–130  ·  view source on GitHub ↗
(uuid: string)

Source from the content-addressed store, hash-verified

113 }
114
115 async disableScript(uuid: string) {
116 // 关闭脚本
117 // 停止定时任务
118 // 检查是否有定时器
119 if (this.cronJob.has(uuid)) {
120 this.stopCronJob(uuid);
121 }
122 // 移除重试队列
123 this.removeRetryList(uuid);
124 if (!this.execScriptMap.has(uuid)) {
125 // 没有在运行
126 return false;
127 }
128 // 停止脚本运行
129 return await this.stopScript(uuid);
130 }
131
132 // 执行脚本
133 async execScript(

Callers 1

enableScriptMethod · 0.95

Calls 4

stopCronJobMethod · 0.95
removeRetryListMethod · 0.95
stopScriptMethod · 0.95
hasMethod · 0.65

Tested by

no test coverage detected