Commit dfe6629a by jyurek

Fixed S3 url generation

git-svn-id: https://svn.thoughtbot.com/plugins/paperclip/trunk@250 7bbfaf0e-4d1d-0410-9690-a8bb5f8ef2aa
parent 849b6b8c
......@@ -12,6 +12,10 @@ module Paperclip
:secret_access_key => secret_key,
:persistent => Paperclip.options[:s3][:persistent] || true
)
class << base
alias_method_chain :url, :s3
end
end
def self.credentials
......@@ -32,7 +36,7 @@ module Paperclip
def url_with_s3 style = nil
http_host = definition.s3_host || "http://s3.amazonaws.com"
"#{http_host}/#{bucket}/#{url_without_s3(style)}"
"#{http_host}/#{bucket}#{url_without_s3(style)}"
end
def file_name style = nil
......
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