X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/99bed16f9a905bf7a167f927cce5f15f9064fd20..f3a9d2e9d61f3f596d559ac75d54c08bc60fc629:/app/controllers/traces/pictures_controller.rb?ds=sidebyside diff --git a/app/controllers/traces/pictures_controller.rb b/app/controllers/traces/pictures_controller.rb index aeac7df86..0e0d588cb 100644 --- a/app/controllers/traces/pictures_controller.rb +++ b/app/controllers/traces/pictures_controller.rb @@ -6,9 +6,9 @@ module Traces authorize_resource :trace def show - trace = Trace.find(params[:trace_id]) + trace = Trace.visible.find(params[:trace_id]) - if trace.visible? && trace.inserted? + if trace.inserted? if trace.public? || (current_user && current_user == trace.user) if trace.icon.attached? redirect_to rails_blob_path(trace.image, :disposition => "inline")