diff --git a/app/controllers/blob_controller.rb b/app/controllers/blob_controller.rb index d68754d0..d4a45d95 100644 --- a/app/controllers/blob_controller.rb +++ b/app/controllers/blob_controller.rb @@ -11,16 +11,9 @@ class BlobController < ProjectResourceController def show if @tree.is_blob? - if @tree.text? - encoding = detect_encoding(@tree.data) - mime_type = encoding ? "text/plain; charset=#{encoding}" : "text/plain" - else - mime_type = @tree.mime_type - end - send_data( @tree.data, - type: mime_type, + type: @tree.mime_type, disposition: 'inline', filename: @tree.name )