]> git.openstreetmap.org Git - rails.git/blobdiff - app/controllers/traces/icons_controller.rb
Fix changeset comments feed timeout
[rails.git] / app / controllers / traces / icons_controller.rb
index c86e391e4ddec5a973856bbb2493b57eb75b6317..a62e6af8630cfa2a22aaa2bd014cee55dfacb520 100644 (file)
@@ -9,12 +9,7 @@ module Traces
       trace = Trace.visible.imported.find(params[:trace_id])
 
       if trace.public? || (current_user && current_user == trace.user)
-        if trace.icon.attached?
-          redirect_to rails_blob_path(trace.icon, :disposition => "inline")
-        else
-          expires_in 7.days, :private => !trace.public?, :public => trace.public?
-          send_file(trace.icon_picture_name, :filename => "#{trace.id}_icon.gif", :type => "image/gif", :disposition => "inline")
-        end
+        redirect_to rails_blob_path(trace.icon, :disposition => "inline")
       else
         head :forbidden
       end