diff --git a/lib/map.js b/lib/map.js index c00669e..09b3f6f 100644 --- a/lib/map.js +++ b/lib/map.js @@ -82,7 +82,11 @@ define(['map/clientlayer', 'map/labellayer', 'map/button', 'leaflet', 'map/activ if (config.geo) { [].forEach.call(config.geo, function (geo) { - L.geoJSON(geo.json, geo.option).addTo(map); + geo.json().then(function (result) { + if (result) { + L.geoJSON(result, geo.option).addTo(map); + } + }); }); }