]> git.openstreetmap.org Git - rails.git/blobdiff - app/assets/javascripts/index/directions.js.erb
Move querystring.js to vendor tree
[rails.git] / app / assets / javascripts / index / directions.js.erb
index 7b1ef3c5b8af4f4e3630bd4f2fed715b73091555..faa9226358f6ca1471f98a7b8788dc386359defe 100644 (file)
@@ -73,7 +73,7 @@ OSM.Directions = function (map) {
 
       endpoint.awaitingGeocode = true;
 
-      $.getJSON('<%= NOMINATIM_URL %>search?q=' + encodeURIComponent(endpoint.value) + '&format=json', function (json) {
+      $.getJSON(document.location.protocol + '<%= NOMINATIM_URL %>search?q=' + encodeURIComponent(endpoint.value) + '&format=json', function (json) {
         endpoint.awaitingGeocode = false;
         endpoint.hasGeocode = true;
         if (json.length == 0) {