diff --git a/leafmap/maplibregl.py b/leafmap/maplibregl.py index 68b8444484..4f89a433e5 100644 --- a/leafmap/maplibregl.py +++ b/leafmap/maplibregl.py @@ -89,7 +89,7 @@ def __init__( if style == "3d-terrain": style = self._get_3d_terrain_style() - if style.lower() in carto_basemaps: + if isinstance(style, str) and (style.lower() in carto_basemaps): style = construct_carto_basemap_url(style.lower()) elif style == "demotiles": style = "https://demotiles.maplibre.org/style.json"