feat: 优化点击等待,补充缺少任务ID的日志等

This commit is contained in:
foxhui
2026-01-16 03:29:13 +08:00
Unverified
parent 3acd8bb17c
commit c0250e43a0
25 changed files with 208 additions and 112 deletions
+6 -2
View File
@@ -77,9 +77,13 @@ export function createQueueManager(queueConfig, callbacks) {
*/
async function cleanupTask(task) {
if (task?.imagePaths) {
const fs = await import('fs');
const fs = await import('fs/promises');
for (const p of task.imagePaths) {
try { fs.unlinkSync(p); } catch (e) { /* ignore */ }
try {
await fs.unlink(p);
} catch (e) {
logger.debug('服务器', `临时文件清理失败: ${p}`);
}
}
}
}