var map = {
    makeFeatures: {
        section: function(json) {
            if (!( "geojson" in json)) {
               return [];
            }
            return [
                L.geoJson(json.geojson, {
                    style: function() {
                        var color = '#fff';
                        if ("display_informations" in json) {
                            color = getTextColor(json.display_informations);
                        }
                        return {
                            color: color,
                            weight: 6,
                            opacity: 1
                        };
                    }
                }),
                L.geoJson(json.geojson, {
                    style: function() {
                        var color = '#008ACA';
                        if ("display_informations" in json) {
                            color = "#" + json.display_informations.color;
                        }
                        return {
                            color: color,
                            weight: 5,
                            opacity: 1
                        };
                    }
                })
            ];
        },
        journey: function(json) {
            return flatMap(json.sections, map.makeFeatures.section);
        },
        address: function(json) {
            return map._makeMarker('address', json);
        },
        administrative_region: function(json) {
            return map._makeMarker('administrative_region', json);
        },
        stop_area: function(json) {
            return map._makeMarker('stop_area', json);
        },
        stop_point: function(json) {
            return map._makeMarker('stop_point', json);
        },
        poi: function(json) {
            return map._makeMarker('poi', json);
        },
        response: function(json) {
            var key = responseCollectionName(json);
            if (key === null) {
                return [];
            }
            var type = getType(key);
            if (!(type in map.makeFeatures)) {
                return [];
            }
            return flatMap(json[key], map.makeFeatures[type]);
        }
    },

    run: function(type, json) {
        var div = $('<div/>');
        // setting for default path of images used by leaflet
        L.Icon.Default.imagePath='lib/img/leaflet/dist/images';
        if (map.makeFeatures[type] instanceof Function) {
            div.addClass('leaflet');
            var m = L.map(div.get(0)).setView([48.843693, 2.373303], 13);
            mapLink = '<a href="http://openstreetmap.org">OpenStreetMap</a>';
            mapquestLink = '<a href="http://www.mapquest.com//">MapQuest</a>';
            mapquestPic = '<img src="http://developer.mapquest.com/content/osm/mq_logo.png">';
            L.tileLayer(
                'http://otile{s}.mqcdn.com/tiles/1.0.0/map/{z}/{x}/{y}.png', {
                    attribution: '&copy; '+mapLink+'. Tiles courtesy of '+mapquestLink+mapquestPic,
                    maxZoom: 17,
                    subdomains: '1234',
            }).addTo(m);
            var overlay = L.featureGroup(map.makeFeatures[type](json)).addTo(m);
            setTimeout(function(){ m.invalidateSize(), m.fitBounds(overlay.getBounds());}, 100);
        } else {
            div.addClass('noMap');
            div.append('No map');
        }
        return div;
    },

    _makeMarker: function(type, json) {
        return [L.marker([json.coord.lat, json.coord.lon]).bindPopup(summary.run(new Context(json), type, json))];
    },
};

@@ -2402,16 +2402,43 @@
 mages';%0A
+        var features = %5B%5D;%0A
         
@@ -2483,16 +2483,80 @@
 Function
+ &&%0A            (features = map.makeFeatures%5Btype%5D(json)).length
 ) %7B%0A    
@@ -3261,36 +3261,16 @@
 oup(
-map.makeFeatures%5Btype%5D(json)
+features
 ).ad
@@ -3311,16 +3311,32 @@
 ction()%7B
+%0A               
  m.inval
@@ -3346,17 +3346,33 @@
 teSize()
-,
+;%0A               
  m.fitBo
@@ -3397,16 +3397,30 @@
 unds());
+%0A%0A            
 %7D, 100);
@@ -3420,16 +3420,17 @@
 , 100);%0A
+%0A
         

fix response without map