lib/cloudfiles/authentication.rb in cloudfiles-1.4.15 vs lib/cloudfiles/authentication.rb in cloudfiles-1.4.16
- old
+ new
@@ -25,9 +25,10 @@
raise CloudFiles::Exception::Connection, "Unable to connect to #{server}"
end
response = server.get(path, hdrhash)
if (response.code =~ /^20./)
if response["x-cdn-management-url"]
+ connection.cdn_available = true
connection.cdnmgmthost = URI.parse(response["x-cdn-management-url"]).host
connection.cdnmgmtpath = URI.parse(response["x-cdn-management-url"]).path
connection.cdnmgmtport = URI.parse(response["x-cdn-management-url"]).port
connection.cdnmgmtscheme = URI.parse(response["x-cdn-management-url"]).scheme
end