X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/8eef66cee2837ce5df84906dbcbf4c5a8df3bea2..a16b45eb6a26ad7738e5d919faaf515708507cbf:/app/controllers/trace_controller.rb diff --git a/app/controllers/trace_controller.rb b/app/controllers/trace_controller.rb index dbb8a6f2c..0ab87f6af 100644 --- a/app/controllers/trace_controller.rb +++ b/app/controllers/trace_controller.rb @@ -163,7 +163,7 @@ class TraceController < ApplicationController trace = Trace.find(params[:id]) if trace.visible? and (trace.public? or (@user and @user == trace.user)) - if Acl.match(request.remote_ip).where(:k => "no_trace_download").exists? + if Acl.no_trace_download(request.remote_ip) render :nothing => true, :status => :forbidden elsif request.format == Mime::XML send_file(trace.xml_file, :filename => "#{trace.id}.xml", :type => Mime::XML.to_s, :disposition => 'attachment')