diff --git a/src/makeCodeHigh.js b/src/makeCodeHigh.js index a7a3385..05c7f9e 100644 --- a/src/makeCodeHigh.js +++ b/src/makeCodeHigh.js @@ -93,7 +93,9 @@ function secondStep(ts, immucfg, mate) { } module.exports = async function (ts, immucfg, mate) { - fse.moveSync(paths.outputResolve('makecode-high'), paths.outputResolve('makecode-high-old'), { overwrite: true }); + if (fs.existsSync(paths.outputResolve('makecode-high'))) { + fse.moveSync(paths.outputResolve('makecode-high'), paths.outputResolve('makecode-high-old'), { overwrite: true }); + } const startTime = new Date().getTime(); const [files, cookieStr] = firstStep(ts, immucfg, mate); files.unshift('\n第1次请求:\n');