Ver código fonte

GLTFExporter: Compare .name with emptry strings for the consistency in the exporter.

Takahiro 7 anos atrás
pai
commit
b8152ba88a
1 arquivos alterados com 3 adições e 3 exclusões
  1. 3 3
      examples/js/exporters/GLTFExporter.js

+ 3 - 3
examples/js/exporters/GLTFExporter.js

@@ -801,7 +801,7 @@ THREE.GLTFExporter.prototype = {
 
 			}
 
-			if ( material.name ) {
+			if ( material.name !== '' ) {
 
 				gltfMaterial.name = material.name;
 
@@ -1079,7 +1079,7 @@ THREE.GLTFExporter.prototype = {
 
 			}
 
-			if ( camera.name ) {
+			if ( camera.name !== '' ) {
 
 				gltfCamera.name = camera.type;
 
@@ -1401,7 +1401,7 @@ THREE.GLTFExporter.prototype = {
 
 			};
 
-			if ( scene.name ) {
+			if ( scene.name !== '' ) {
 
 				gltfScene.name = scene.name;