lib/evrythng/request.rb in evrythng-0.0.1 vs lib/evrythng/request.rb in evrythng-0.0.2
- old
+ new
@@ -26,19 +26,15 @@
# Perform an HTTP request
def request(method, path, options, raw=false)
response = connection(raw).send(method) do |request|
case method
when :get, :delete
- request.url(formatted_path(path), options)
+ request.url(path, options)
when :post, :put
- request.path = formatted_path(path)
+ request.path = path
request.body = options unless options.empty?
end
end
raw ? response : response.body
- end
-
- def formatted_path(path)
- [path, format].compact.join('.')
end
end
end