Commit 0167bf29 by Andy Stewart

Remove duplication by reusing existing method.

parent e4fd8657
...@@ -379,11 +379,9 @@ module Paperclip ...@@ -379,11 +379,9 @@ module Paperclip
retries = 0 retries = 0
begin begin
log("saving #{path(style)}") log("saving #{path(style)}")
acl = @s3_permissions[style] || @s3_permissions[:default]
acl = acl.call(self, style) if acl.respond_to?(:call)
write_options = { write_options = {
:content_type => file.content_type, :content_type => file.content_type,
:acl => acl :acl => s3_permissions(style)
} }
# add storage class for this style if defined # add storage class for this style if defined
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment