继续可持续性的竭泽而渔

This commit is contained in:
aixianling
2023-01-19 10:38:53 +08:00
parent 7bcc5c3de8
commit e7fd86b1e2

View File

@@ -3,7 +3,7 @@ const execute = require("../../tools/exec")
const dayjs = require("dayjs")
const fse = require("fs-extra");
const controller = new AbortController()
let controller = new AbortController()
const handleZip = (id, ws) => {
const uniCon = `id='${id}'`
const sendMessage = data => ws.send(JSON.stringify(data))
@@ -85,6 +85,7 @@ module.exports = {
const data = JSON.parse(res.data)
if (data.cid == id) {
controller.abort()
controller = new AbortController()
} else if (id == data.id) {
handleZip(id, ws)
}