lib/cmis/connection.rb in cmis-ruby-0.4.9 vs lib/cmis/connection.rb in cmis-ruby-0.4.10

- old
+ new

@@ -1,5 +1,6 @@ +require 'cmis/connection/follow_redirects' require 'cmis/connection/request_modifier' require 'cmis/connection/response_parser' require 'cmis/version' require 'faraday' @@ -17,10 +18,11 @@ if options[:username] builder.basic_auth(options[:username], options[:password]) end builder.adapter (options[:adapter] || :net_http).to_sym + builder.use FollowRedirects builder.response :logger if options[:log_requests] builder.use ResponseParser end @repository_infos = {} @@ -29,10 +31,10 @@ def do_request(params, query, headers) repository_id = params.delete(:repositoryId) url = infer_url(repository_id, params[:objectId]) if params[:cmisaction] - @http.post(url, params, headers) + @http.post(url, params, headers) { |req| req.params = query } else @http.get(url, params.merge(query), headers) end end