Browse Source

Merge pull request #12966 from takahirox/FixGLTFExporterCache

Fix GLTFExporter cachedData check
Mr.doob 7 years ago
parent
commit
175181050c
1 changed files with 2 additions and 2 deletions
  1. 2 2
      examples/js/exporters/GLTFExporter.js

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

@@ -396,7 +396,7 @@ THREE.GLTFExporter.prototype = {
 		 */
 		 */
 		function processImage( map ) {
 		function processImage( map ) {
 
 
-			if ( cachedData.images[ map.uuid ] ) {
+			if ( cachedData.images[ map.uuid ] !== undefined ) {
 
 
 				return cachedData.images[ map.uuid ];
 				return cachedData.images[ map.uuid ];
 
 
@@ -507,7 +507,7 @@ THREE.GLTFExporter.prototype = {
 		 */
 		 */
 		function processMaterial( material ) {
 		function processMaterial( material ) {
 
 
-			if ( cachedData.materials[ material.uuid ] ) {
+			if ( cachedData.materials[ material.uuid ] !== undefined ) {
 
 
 				return cachedData.materials[ material.uuid ];
 				return cachedData.materials[ material.uuid ];