$(this).show();
});
- $.ajax({
- url: "http://overpass-api.de/api/interpreter",
+ if ($section.data("ajax")) {
+ $section.data("ajax").abort();
+ }
+
+ $section.data("ajax", $.ajax({
+ url: OSM.OVERPASS_URL,
method: "POST",
data: {
data: "[timeout:5][out:json];" + query,
.appendTo($ul);
}
}
- });
+ }));
}
function queryOverpass(lat, lng) {