X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/6339473cb77e4e0998b959a0835a8f42767f608d..1522ed275c3efceb9629438e0272f2f2d4adf5ba:/app/controllers/way_controller.rb diff --git a/app/controllers/way_controller.rb b/app/controllers/way_controller.rb index 25d535d79..80c75d91c 100644 --- a/app/controllers/way_controller.rb +++ b/app/controllers/way_controller.rb @@ -22,6 +22,7 @@ class WayController < ApplicationController render :nothing => true, :status => :method_not_allowed end rescue OSM::APIError => ex + logger.warn request.raw_post render ex.render_opts end end @@ -56,6 +57,7 @@ class WayController < ApplicationController render :nothing => true, :status => :bad_request end rescue OSM::APIError => ex + logger.warn request.raw_post render ex.render_opts rescue ActiveRecord::RecordNotFound render :nothing => true, :status => :not_found @@ -87,7 +89,7 @@ class WayController < ApplicationController if way.visible nd_ids = way.nds + [-1] - nodes = Node.find(:all, :conditions => "visible = 1 AND id IN (#{nd_ids.join(',')})") + nodes = Node.find(:all, :conditions => ["visible = ? AND id IN (#{nd_ids.join(',')})", true]) # Render doc = OSM::API.new.get_xml_doc