var geojsonLayerIncidents = new L.GeoJSON.AJAX("http://131940.qld.gov.au/api/json/v1/events/incident",{
middleware:function(data){
return L.geoJson(data, {
onEachFeature: function (feature, layer) {
layer.setIcon(incidentIcon);
layer.bindPopup ("Incident<p>Road: "+feature.properties.location.road+"<p>Direction: "+feature.properties.location.direction);
}
}).addTo(map);
}
});