Prechádzať zdrojové kódy

LWOLoader: case insensitive texture path

Guilherme Avila 6 rokov pred
rodič
commit
0c55b834fb
1 zmenil súbory, kde vykonal 1 pridanie a 1 odobranie
  1. 1 1
      examples/js/loaders/LWOLoader.js

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

@@ -678,7 +678,7 @@ THREE.LWOLoader = ( function () {
 		// In this case, we'll strip out everything and load 'bumpMap.png' from the same directory as the model
 		// In this case, we'll strip out everything and load 'bumpMap.png' from the same directory as the model
 		cleanPath( path ) {
 		cleanPath( path ) {
 
 
-			if ( path.indexOf( 'Images' ) === 0 || path.indexOf( 'images' ) === 0 ) return './' + path;
+			if ( path.toLowerCase().indexOf( 'images' ) === 0 ) return './' + path;
 			return path.split( '/' ).pop().split( '\\' ).pop();
 			return path.split( '/' ).pop().split( '\\' ).pop();
 
 
 		},
 		},