app/helpers/smithy/upload_helper.rb in smithycms-0.5.1 vs app/helpers/smithy/upload_helper.rb in smithycms-0.5.2

- old
+ new

@@ -63,10 +63,11 @@ :key => key, :acl => @options[:acl], :policy => policy, :signature => signature, "AWSAccessKeyId" => @options[:aws_access_key_id], + "Content-Type" => nil } end def key @key ||= "uploads/assets/#{SecureRandom.hex}/${filename}" @@ -84,9 +85,10 @@ { expiration: @options[:expiration].utc.iso8601, conditions: [ ["starts-with", "$utf8", ""], ["starts-with", "$key", ""], + ["starts-with", "$Content-Type", ""], ["content-length-range", 0, @options[:max_file_size]], {bucket: @options[:bucket]}, {acl: @options[:acl]} ] }