Browse Source

Nodes: remove redundant code (#28173)

Co-authored-by: aardgoose <[email protected]>
aardgoose 1 year ago
parent
commit
d1078e756a
1 changed files with 5 additions and 8 deletions
  1. 5 8
      examples/jsm/nodes/core/NodeBuilder.js

+ 5 - 8
examples/jsm/nodes/core/NodeBuilder.js

@@ -1086,21 +1086,18 @@ class NodeBuilder {
 
 	}
 
-	build( convertMaterial = true ) {
+	build() {
 
 		const { object, material } = this;
 
-		if ( convertMaterial ) {
 
-			if ( material !== null ) {
+		if ( material !== null ) {
 
-				NodeMaterial.fromMaterial( material ).build( this );
+			NodeMaterial.fromMaterial( material ).build( this );
 
-			} else {
-
-				this.addFlow( 'compute', object );
+		} else {
 
-			}
+			this.addFlow( 'compute', object );
 
 		}