@@ -35,7 +35,9 class AttachmentsController < ApplicationController | |||
|
35 | 35 | end |
|
36 | 36 | |
|
37 | 37 | def download |
|
38 | @attachment.increment_download if @attachment.container.is_a?(Version) | |
|
38 | if @attachment.container.is_a?(Version) || @attachment.container.is_a?(Project) | |
|
39 | @attachment.increment_download | |
|
40 | end | |
|
39 | 41 | |
|
40 | 42 | # images are sent inline |
|
41 | 43 | send_file @attachment.diskfile, :filename => filename_for_content_disposition(@attachment.filename), |
General Comments 0
You need to be logged in to leave comments.
Login now