Fix extension node def manipulation (#2873)

This commit is contained in:
Chenlei Hu
2025-03-05 11:18:58 -05:00
committed by GitHub
parent b80c991299
commit 621568f99e
3 changed files with 34 additions and 41 deletions

View File

@@ -70,6 +70,12 @@ export class ComfyNodeDefImpl implements ComfyNodeDefV1, ComfyNodeDefV2 {
readonly nodeSource: NodeSource
constructor(obj: ComfyNodeDefV1) {
/**
* Assign extra fields to `this` for compatibility with group node feature.
* TODO: Remove this once group node feature is removed.
*/
Object.assign(this, obj)
// Initialize V1 fields
this.name = obj.name
this.display_name = obj.display_name