Explorar el Código

Merge pull request #19046 from yomboprime/hasefroch

LDrawLoader (packLDrawModel.js) Fix LGTM error
Mr.doob hace 5 años
padre
commit
5c18dfc033
Se han modificado 1 ficheros con 2 adiciones y 2 borrados
  1. 2 2
      utils/packLDrawModel.js

+ 2 - 2
utils/packLDrawModel.js

@@ -222,7 +222,7 @@ function parseObject( fileName, isRoot ) {
 
 			// Embedded object was found, add to path map
 
-			var subobjectFileName = line.substring( charIndex ).trim().replace( "\\", "/" );
+			var subobjectFileName = line.substring( charIndex ).trim().replace( /\\/g, '/' );
 
 			if ( subobjectFileName ) {
 
@@ -263,7 +263,7 @@ function parseObject( fileName, isRoot ) {
 
 			}
 
-			var subobjectFileName = line.substring( charIndex ).trim().replace( "\\", "/" );
+			var subobjectFileName = line.substring( charIndex ).trim().replace( /\\/g, '/' );
 
 			if ( subobjectFileName ) {