mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-09-13 13:05:07 +00:00
Don't hardcode node names for image upload widget.
This commit is contained in:
@@ -5,7 +5,8 @@ import { app } from "../../scripts/app.js";
|
||||
app.registerExtension({
|
||||
name: "Comfy.UploadImage",
|
||||
async beforeRegisterNodeDef(nodeType, nodeData, app) {
|
||||
if (nodeData.name === "LoadImage" || nodeData.name === "LoadImageMask") {
|
||||
console.log(nodeData);
|
||||
if (nodeData?.input?.required?.image?.[1]?.image_upload === true) {
|
||||
nodeData.input.required.upload = ["IMAGEUPLOAD"];
|
||||
}
|
||||
},
|
||||
|
Reference in New Issue
Block a user