File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -405,7 +405,7 @@ export class WebMap extends ol.Observable {
405
405
maxResolution = Math . max ( maxResolution1 , maxResolution2 ) ;
406
406
}
407
407
408
- if ( options . baseLayer . visibleScales ) {
408
+ if ( options . baseLayer . visibleScales && options . baseLayer . visibleScales . length > 0 ) {
409
409
maxZoom = options . baseLayer . visibleScales . length ;
410
410
}
411
411
@@ -688,7 +688,7 @@ export class WebMap extends ol.Observable {
688
688
prjCoordSys :{ epsgCode : isBaseLayer ? layerInfo . projection . split ( ':' ) [ 1 ] : this . baseProjection . split ( ':' ) [ 1 ] } ,
689
689
tileProxy : this . tileProxy
690
690
} ;
691
- if ( layerInfo . visibleScales ) {
691
+ if ( layerInfo . visibleScales && layerInfo . visibleScales . length > 0 ) {
692
692
let result = this . getReslutionsFromScales ( layerInfo . visibleScales , 96 , layerInfo . coordUnit ) ;
693
693
let tileGrid = new ol . tilegrid . TileGrid ( {
694
694
extent : layerInfo . extent ,
You can’t perform that action at this time.
0 commit comments