aebadirad / Leaflet.AutoLayers

A dynamic leaflet layers control that pulls from multiple mapservers and manages basemaps and overlays plus order
MIT License
31 stars 21 forks source link

when mapServers is empty, where will have problems #1

Closed AnchorRen closed 8 years ago

AnchorRen commented 8 years ago

you said the 'mapServers' is OPTIONAL,but when i set config like this: var config = { overlays:overlays, selectedBasemap: 'OpenStreetMap', selectedOverlays: ["cities"], baseLayers:baseLayers, }; there will be a problem in leaflet-autolayers.js:397 ERROR is : Uncaught TypeError: Cannot read property 'length' of undefined

aebadirad commented 8 years ago

Good find. Updated on master branch to fix this bug.