Merge branch 'ruby-2.1'
Conflicts: app/assets/javascripts/comments.js app/helpers/delayed_jobs_helper.rb
This commit is contained in:
@@ -201,13 +201,13 @@ class Upload < ActiveRecord::Base
|
||||
|
||||
def file_header_to_content_type(source_path)
|
||||
case File.read(source_path, 10)
|
||||
when /^\xff\xd8/
|
||||
when /^\xff\xd8/n
|
||||
"image/jpeg"
|
||||
|
||||
when /^GIF87a/, /^GIF89a/
|
||||
"image/gif"
|
||||
|
||||
when /^\x89PNG\r\n\x1a\n/
|
||||
when /^\x89PNG\r\n\x1a\n/n
|
||||
"image/png"
|
||||
|
||||
when /^CWS/, /^FWS/, /^ZWS/
|
||||
|
||||
Reference in New Issue
Block a user