swift_client 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/swift_client.rb +3 -1
- data/lib/swift_client/version.rb +1 -1
- metadata +1 -1
data/lib/swift_client.rb
CHANGED
@@ -167,12 +167,14 @@ class SwiftClient
|
|
167
167
|
headers["X-Auth-Token"] = auth_token
|
168
168
|
headers["Accept"] = "application/json"
|
169
169
|
|
170
|
+
stream_pos = opts[:body_stream].pos if opts[:body_stream]
|
171
|
+
|
170
172
|
response = HTTParty.send(method, "#{storage_url}#{path}", opts.merge(:headers => headers))
|
171
173
|
|
172
174
|
if response.code == 401
|
173
175
|
authenticate
|
174
176
|
|
175
|
-
opts[:body_stream].
|
177
|
+
opts[:body_stream].pos = stream_pos if opts[:body_stream]
|
176
178
|
|
177
179
|
return request(method, path, opts)
|
178
180
|
end
|
data/lib/swift_client/version.rb
CHANGED