@@ -57,7 +57,7 class AttachmentsController < ApplicationController | |||
|
57 | 57 | # images are sent inline |
|
58 | 58 | send_file @attachment.diskfile, :filename => filename_for_content_disposition(@attachment.filename), |
|
59 | 59 | :type => detect_content_type(@attachment), |
|
60 |
:disposition => |
|
|
60 | :disposition => 'attachment' | |
|
61 | 61 | end |
|
62 | 62 | end |
|
63 | 63 |
@@ -177,7 +177,7 class RepositoriesController < ApplicationController | |||
|
177 | 177 | send_opt = { :filename => filename_for_content_disposition(@path.split('/').last) } |
|
178 | 178 | send_type = Redmine::MimeType.of(@path) |
|
179 | 179 | send_opt[:type] = send_type.to_s if send_type |
|
180 | send_opt[:disposition] = (Redmine::MimeType.is_type?('image', @path) && !is_raw ? 'inline' : 'attachment') | |
|
180 | send_opt[:disposition] = 'attachment' | |
|
181 | 181 | send_data @content, send_opt |
|
182 | 182 | else |
|
183 | 183 | # Prevent empty lines when displaying a file with Windows style eol |
General Comments 0
You need to be logged in to leave comments.
Login now