mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
Put escaping logic into the collection get_url call.
This commit is contained in:
parent
016d640683
commit
559384ff4a
2 changed files with 2 additions and 2 deletions
|
@ -50,7 +50,7 @@ module Fog
|
|||
|
||||
def public_url
|
||||
requires :key
|
||||
self.collection.get_url(Fog::Rackspace.escape(self.key, '/'))
|
||||
self.collection.get_url(self.key)
|
||||
end
|
||||
|
||||
def save(options = {})
|
||||
|
|
|
@ -67,7 +67,7 @@ module Fog
|
|||
def get_url(key)
|
||||
requires :directory
|
||||
if self.directory.public_url
|
||||
"#{self.directory.public_url}/#{key}"
|
||||
"#{self.directory.public_url}/#{Fog::Rackspace.escape(key, '/')}"
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue