X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/d702a29810989e36a1fc2633ae424ee25e07967f..2e43a275de10e162d605df71e3e0f16ba596ad25:/app/controllers/geocoder_controller.rb?ds=sidebyside diff --git a/app/controllers/geocoder_controller.rb b/app/controllers/geocoder_controller.rb index 8394b3e6e..aaa8d17ef 100644 --- a/app/controllers/geocoder_controller.rb +++ b/app/controllers/geocoder_controller.rb @@ -357,8 +357,8 @@ class GeocoderController < ApplicationController response = fetch_xml("http://nominatim.openstreetmap.org/reverse?lat=#{lat}&lon=#{lon}&zoom=#{zoom}&accept-language=#{request.user_preferred_languages.join(',')}") # parse the response - response.elements.each("reversegeocode") do |result| - description = result.get_text("result").to_s + response.elements.each("reversegeocode/result") do |result| + description = result.get_text.to_s @results.push({:prefix => "#{description}"}) end