fog 0.0.97 → 0.0.98

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -7,7 +7,7 @@ Gem::Specification.new do |s|
7
7
  ## If your rubyforge_project name is different, then edit it and comment out
8
8
  ## the sub! line in the Rakefile
9
9
  s.name = 'fog'
10
- s.version = '0.0.97'
10
+ s.version = '0.0.98'
11
11
  s.date = '2010-05-14'
12
12
  s.rubyforge_project = 'fog'
13
13
 
data/lib/fog.rb CHANGED
@@ -35,7 +35,7 @@ require 'fog/vcloud'
35
35
  module Fog
36
36
 
37
37
  unless const_defined?(:VERSION)
38
- VERSION = '0.0.97'
38
+ VERSION = '0.0.98'
39
39
  end
40
40
 
41
41
  module Mock
@@ -25,7 +25,15 @@ module Fog
25
25
  # * 'ETag'<~String> - Etag of object
26
26
  # * 'Last-Modified'<~String> - Last modified timestamp for object
27
27
  def head_object(bucket_name, object_name, options={})
28
- version_id = options.delete('versionId')
28
+ unless bucket_name
29
+ raise ArgumentError.new('bucket_name is required')
30
+ end
31
+ unless object_name
32
+ raise ArgumentError.new('object_name is required')
33
+ end
34
+ if version_id = options.delete('versionId')
35
+ query = CGI.escape(version_id)
36
+ end
29
37
  headers = {}
30
38
  headers['If-Modified-Since'] = options['If-Modified-Since'].utc.strftime("%a, %d %b %Y %H:%M:%S +0000") if options['If-Modified-Since']
31
39
  headers['If-Unmodified-Since'] = options['If-Unmodified-Since'].utc.strftime("%a, %d %b %Y %H:%M:%S +0000") if options['If-Modified-Since']
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 97
9
- version: 0.0.97
8
+ - 98
9
+ version: 0.0.98
10
10
  platform: ruby
11
11
  authors:
12
12
  - geemus (Wesley Beary)