Commit b04e16ef authored by comfyanonymous's avatar comfyanonymous
Browse files

Make default workflow use an existing checkpoint if no SD1.5 checkpoint.

parent 0aa667ed
......@@ -971,8 +971,10 @@ export class ComfyApp {
loadGraphData(graphData) {
this.clean();
let reset_invalid_values = false;
if (!graphData) {
graphData = structuredClone(defaultGraph);
reset_invalid_values = true;
}
const missingNodeTypes = [];
......@@ -1058,6 +1060,13 @@ export class ComfyApp {
}
}
}
if (reset_invalid_values) {
if (widget.type == "combo") {
if (!widget.options.values.includes(widget.value) && widget.options.values.length > 0) {
widget.value = widget.options.values[0];
}
}
}
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment