Commit 8a8846151e553e4928ecd638175c3b3d7b0b9f87
1 parent
cf9140ee
Exists in
master
and in
22 other branches
Not store article as origin location for downloads
Showing
1 changed file
with
3 additions
and
1 deletions
Show diff stats
app/controllers/public/content_viewer_controller.rb
| ... | ... | @@ -52,7 +52,6 @@ class ContentViewerController < ApplicationController |
| 52 | 52 | |
| 53 | 53 | # At this point the page will be showed |
| 54 | 54 | @page.hit |
| 55 | - store_location | |
| 56 | 55 | |
| 57 | 56 | unless @page.mime_type == 'text/html' || (@page.image? && params[:view]) |
| 58 | 57 | headers['Content-Type'] = @page.mime_type |
| ... | ... | @@ -67,6 +66,9 @@ class ContentViewerController < ApplicationController |
| 67 | 66 | return |
| 68 | 67 | end |
| 69 | 68 | |
| 69 | + # store location if the page is not a download | |
| 70 | + store_location | |
| 71 | + | |
| 70 | 72 | @form_div = params[:form] |
| 71 | 73 | |
| 72 | 74 | if request.post? && params[:comment] && params[self.icaptcha_field].blank? && @page.accept_comments? | ... | ... |