mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
add query param to get_object_http_url for consistency
This commit is contained in:
parent
f026d3533e
commit
491ec8fb74
2 changed files with 6 additions and 5 deletions
|
@ -78,9 +78,9 @@ module Fog
|
|||
end
|
||||
end
|
||||
|
||||
def get_http_url(key, expires)
|
||||
def get_http_url(key, expires, options = {})
|
||||
requires :directory
|
||||
connection.get_object_http_url(directory.key, key, expires)
|
||||
connection.get_object_http_url(directory.key, key, expires, options)
|
||||
end
|
||||
|
||||
def get_https_url(key, expires, options = {})
|
||||
|
|
|
@ -4,7 +4,7 @@ module Fog
|
|||
|
||||
module GetObjectHttpUrl
|
||||
|
||||
def get_object_http_url(bucket_name, object_name, expires)
|
||||
def get_object_http_url(bucket_name, object_name, expires, options = {})
|
||||
unless bucket_name
|
||||
raise ArgumentError.new('bucket_name is required')
|
||||
end
|
||||
|
@ -15,7 +15,8 @@ module Fog
|
|||
:headers => {},
|
||||
:host => @host,
|
||||
:method => 'GET',
|
||||
:path => "#{bucket_name}/#{object_name}"
|
||||
:path => "#{bucket_name}/#{object_name}",
|
||||
:query => options[:query]
|
||||
}, expires)
|
||||
end
|
||||
|
||||
|
@ -48,4 +49,4 @@ module Fog
|
|||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue