Rename node to JSONDynamicLoader to avoid collision with JSON Manager
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -79,7 +79,7 @@ if PromptServer is not None:
|
||||
return web.json_response({"keys": keys, "types": types})
|
||||
|
||||
|
||||
class JSONLoaderDynamic:
|
||||
class JSONDynamicLoader:
|
||||
@classmethod
|
||||
def INPUT_TYPES(s):
|
||||
return {
|
||||
@@ -124,9 +124,9 @@ class JSONLoaderDynamic:
|
||||
|
||||
|
||||
NODE_CLASS_MAPPINGS = {
|
||||
"JSONLoaderDynamic": JSONLoaderDynamic,
|
||||
"JSONDynamicLoader": JSONDynamicLoader,
|
||||
}
|
||||
|
||||
NODE_DISPLAY_NAME_MAPPINGS = {
|
||||
"JSONLoaderDynamic": "JSON Loader (Dynamic)",
|
||||
"JSONDynamicLoader": "JSON Dynamic Loader",
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@ app.registerExtension({
|
||||
name: "json.dynamic.loader",
|
||||
|
||||
async beforeRegisterNodeDef(nodeType, nodeData, app) {
|
||||
if (nodeData.name !== "JSONLoaderDynamic") return;
|
||||
if (nodeData.name !== "JSONDynamicLoader") return;
|
||||
|
||||
const origOnNodeCreated = nodeType.prototype.onNodeCreated;
|
||||
nodeType.prototype.onNodeCreated = function () {
|
||||
@@ -96,7 +96,7 @@ app.registerExtension({
|
||||
this.setSize(this.computeSize());
|
||||
app.graph.setDirtyCanvas(true, true);
|
||||
} catch (e) {
|
||||
console.error("[JSONLoaderDynamic] Refresh failed:", e);
|
||||
console.error("[JSONDynamicLoader] Refresh failed:", e);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user