fix no wifi issue after building
This commit is contained in:
@@ -11,6 +11,15 @@ export function getBuildStream(id: string): BuildStream | undefined {
|
||||
}
|
||||
|
||||
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);
|
||||
}
|
||||
|
||||
|
||||
@@ -186,6 +186,15 @@ export async function startBuildProcess(
|
||||
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;
|
||||
|
||||
Reference in New Issue
Block a user