Skip to content

Kepler.gl is a powerful open source geospatial analysis tool for large-scale data sets.

[fix] fix visible layers toggle for split maps mode(#2168)

Igor Dykhta8896dc13c5ee
diff --git a/src/utils/src/map-utils.ts b/src/utils/src/map-utils.ts
index a373246a7..bcee61a85 100644
--- a/src/utils/src/map-utils.ts
+++ b/src/utils/src/map-utils.ts
@@ -26,9 +26,9 @@ export const onViewPortChange = (
export const getMapLayersFromSplitMaps = (
splitMaps: SplitMap[],
- mapIndex?: number | undefined
+ mapIndex?: number
): SplitMapLayers | undefined | null => {
- return splitMaps[mapIndex || '']?.layers;
+ return splitMaps[mapIndex || 0]?.layers;
};
/**