xzw 6 months ago
parent
commit
e048a29cc4
1 changed files with 2 additions and 3 deletions
  1. 2 3
      src/sdk/cover/index.js

+ 2 - 3
src/sdk/cover/index.js

@@ -90,9 +90,8 @@ export const enter = ({ dom, mapDom, isLocal, lonlat, scenes, laserRoot, laserOS
         } 
         
     }
-    if(laserRoot != void 0){
-        laserRoot.slice(-1) == '/' && (laserRoot = laserRoot.slice(0,-1)) //去掉最后一个'/'
-        Potree.settings.urls.prefix = laserRoot
+    if(laserRoot != void 0){ 
+        Potree.settings.urls.prefix = Potree.settings.urls.handlePrefix(laserRoot)
     }
      
     if(laserOSSRoot != void 0){