Class: JIRA::HttpClient

Inherits:
RequestClient show all
Defined in:
lib/mongo/jira/patch.rb

Instance Method Summary collapse

Methods inherited from RequestClient

#request

Instance Method Details

#make_request(http_method, path, body = '', headers = {}, &block) ⇒ Object



19
20
21
22
23
24
# File 'lib/mongo/jira/patch.rb', line 19

def make_request(http_method, path, body='', headers={}, &block)
  request = Net::HTTP.const_get(http_method.to_s.capitalize).new(path, headers)
  request.body = body unless body.nil?
  request.basic_auth(@options[:username], @options[:password])
  basic_auth_http_conn.request(request, &block)
end