fix no wifi issue after building

This commit is contained in:
KingKDot
2026-03-26 16:25:06 -05:00
parent 9751807401
commit 62929c7bc5
3 changed files with 19 additions and 1 deletions
+1 -1
View File
@@ -786,7 +786,7 @@ async function streamBuildOutput(buildId, config = {}) {
displayBuild(buildData); displayBuild(buildData);
} }
reader.releaseLock(); reader.cancel();
return; return;
} else if (data.type === "error") { } else if (data.type === "error") {
addBuildOutput(`\nERROR: ${data.error}\n`, "error"); addBuildOutput(`\nERROR: ${data.error}\n`, "error");
@@ -11,6 +11,15 @@ export function getBuildStream(id: string): BuildStream | undefined {
} }
export function deleteBuildStream(id: string): boolean { export function deleteBuildStream(id: string): boolean {
const build = activeBuildStreams.get(id);
if (build) {
build.controllers.forEach((controller) => {
try {
controller.close();
} catch {}
});
build.controllers.length = 0;
}
return activeBuildStreams.delete(id); return activeBuildStreams.delete(id);
} }
@@ -186,6 +186,15 @@ export async function startBuildProcess(
logger.error("[build] Failed to send to stream:", err); logger.error("[build] Failed to send to stream:", err);
} }
}); });
if (data.type === "complete") {
build.controllers.forEach((controller) => {
try {
controller.close();
} catch {}
});
build.controllers.length = 0;
}
}; };
let winresTempDir: string | null = null; let winresTempDir: string | null = null;