Explorar o código

update name lowercase logic

Garrett Johnson %!s(int64=6) %!d(string=hai) anos
pai
achega
8a4ca06b03
Modificáronse 1 ficheiros con 7 adicións e 1 borrados
  1. 7 1
      examples/js/loaders/LDrawLoader.js

+ 7 - 1
examples/js/loaders/LDrawLoader.js

@@ -279,7 +279,13 @@ THREE.LDrawLoader = ( function () {
 				var parentParseScope = scope.getParentParseScope();
 
 				// Add to cache
-				var currentFileName = parentParseScope.currentFileName && parentParseScope.currentFileName.toLowerCase();
+				var currentFileName = parentParseScope.currentFileName;
+				if ( currentFileName !== null ) {
+
+					currentFileName = parentParseScope.currentFileName.toLowerCase();
+
+				}
+
 				if ( scope.subobjectCache[ currentFileName ] === undefined ) {
 
 					scope.subobjectCache[ currentFileName ] = text;