mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-04-30 11:11:53 +00:00
resolve "TypeError: Cannot redefine property: shape" issue
When same node registered twice. It gives error.
ex:
LiteGraph.registerNodeType("basic/test", MyAddNode);
LiteGraph.registerNodeType("basic/test", MyAddNode);
To redefine an object property with "Object.defineProperty" method, configurable property should be set on true ( default is false)
ex : Object.defineProperty( '...' , '...' , {configurable: true})
This commit is contained in:
@@ -159,7 +159,8 @@
|
|||||||
get: function(v) {
|
get: function(v) {
|
||||||
return this._shape;
|
return this._shape;
|
||||||
},
|
},
|
||||||
enumerable: true
|
enumerable: true,
|
||||||
|
configurable: true
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user