]> git.openstreetmap.org Git - rails.git/commitdiff
Remove redundant code
authorTom Hughes <tom@compton.nu>
Sun, 23 Sep 2012 14:07:35 +0000 (15:07 +0100)
committerTom Hughes <tom@compton.nu>
Sun, 23 Sep 2012 14:07:35 +0000 (15:07 +0100)
app/assets/javascripts/notes.js.erb

index 4df32264c35068d1d855a39ce4a206f4883d2cff..01264bcb65c1f23886f2a7a5bb9eb0a03dadbc76 100644 (file)
@@ -1,12 +1,6 @@
 function addNoteLayer(map, notesUrl, newNoteControls, newNoteForm, minZoom) {
   var newNotes;
 
 function addNoteLayer(map, notesUrl, newNoteControls, newNoteForm, minZoom) {
   var newNotes;
 
-  var noteCallback = function (scope, response) {
-    for (var f = 0; f < response.features.length; f++) {
-      var feature = response.features[f];
-    }
-  };
-
   var saveNewNotes = function (o) {
     var layer = o.object;
     newNotes = layer.getFeaturesByAttribute("status", "new")
   var saveNewNotes = function (o) {
     var layer = o.object;
     newNotes = layer.getFeaturesByAttribute("status", "new")
@@ -167,8 +161,7 @@ function addNoteLayer(map, notesUrl, newNoteControls, newNoteForm, minZoom) {
     ],
     protocol: new OpenLayers.Protocol.HTTP({
       url: notesUrl,
     ],
     protocol: new OpenLayers.Protocol.HTTP({
       url: notesUrl,
-      format: new OpenLayers.Format.GeoJSON(),
-      callback: noteCallback
+      format: new OpenLayers.Format.GeoJSON()
     })
   });
 
     })
   });