Browse Source

Accept undefined scene.nodes

Takahiro 8 years ago
parent
commit
6c96a31043
1 changed files with 1 additions and 1 deletions
  1. 1 1
      examples/js/loaders/GLTFLoader.js

+ 1 - 1
examples/js/loaders/GLTFLoader.js

@@ -2118,7 +2118,7 @@ THREE.GLTFLoader = ( function () {
 
 				if ( scene.extras ) _scene.userData = scene.extras;
 
-				var nodes = scene.nodes;
+				var nodes = scene.nodes || [];
 
 				for ( var i = 0, l = nodes.length; i < l; i ++ ) {