From 8dc2542721ed5c0c2f5f44ff408306c7328adce7 Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Tue, 4 Jul 2017 18:44:06 +0200 Subject: [PATCH] Wait on Marcel for now --- lib/active_file/blob.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/active_file/blob.rb b/lib/active_file/blob.rb index 74fadf5109..d8b9cd07d2 100644 --- a/lib/active_file/blob.rb +++ b/lib/active_file/blob.rb @@ -13,8 +13,9 @@ class ActiveFile::Blob < ActiveRecord::Base class << self def build_after_upload(io:, filename:, content_type: nil, metadata: nil) new.tap do |blob| - blob.content_type = content_type # Marcel::MimeType.for(data, name: name, declared_type: content_type) blob.filename = filename + blob.content_type = content_type + blob.upload io end end