Просмотр исходного кода

[b3dm] - only append / to working path during load if the path is not empty

Dave Buchhofer 3 лет назад
Родитель
Сommit
46ad812c79
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      src/three/B3DMLoader.js

+ 1 - 1
src/three/B3DMLoader.js

@@ -41,7 +41,7 @@ export class B3DMLoader extends B3DMLoaderBase {
 
 			// GLTFLoader assumes the working path ends in a slash
 			let workingPath = this.workingPath;
-			if ( ! /[\\/]$/.test( workingPath ) ) {
+			if ( ! /[\\/]$/.test( workingPath ) && workingPath.length ) {
 
 				workingPath += '/';