Browse Source

Nodes: StorageArrayElementNode - Remove check for non-existant property. (#29276)

* Remove unused property

* cleanup

---------
Christian Helgeson 1 year ago
parent
commit
0bf5f09ecb
1 changed files with 3 additions and 5 deletions
  1. 3 5
      src/nodes/utils/StorageArrayElementNode.js

+ 3 - 5
src/nodes/utils/StorageArrayElementNode.js

@@ -33,7 +33,7 @@ class StorageArrayElementNode extends ArrayElementNode {
 
 		if ( builder.isAvailable( 'storageBuffer' ) === false ) {
 
-			if ( ! this.node.instanceIndex && this.node.bufferObject === true ) {
+			if ( this.node.bufferObject === true ) {
 
 				builder.setupPBO( this.node );
 
@@ -55,15 +55,13 @@ class StorageArrayElementNode extends ArrayElementNode {
 
 		if ( builder.isAvailable( 'storageBuffer' ) === false ) {
 
-			const { node } = this;
-
-			if ( ! node.instanceIndex && this.node.bufferObject === true && isAssignContext !== true ) {
+			if ( this.node.bufferObject === true && isAssignContext !== true ) {
 
 				snippet = builder.generatePBO( this );
 
 			} else {
 
-				snippet = node.build( builder );
+				snippet = this.node.build( builder );
 
 			}
 

粤ICP备19079148号