Class: BaseRepository

Inherits:
Object
  • Object
show all
Defined in:
lib/metonym/lib/repositories/base_repository.rb

Instance Method Summary collapse

Instance Method Details

#request(uri, query:, resource:) ⇒ Object



4
5
6
7
8
# File 'lib/metonym/lib/repositories/base_repository.rb', line 4

def request(uri, query:, resource:)
  uri = URI(uri += resource)
  uri.query = URI.encode_www_form(prepare_arguments(query))
  Net::HTTP.get_response(uri)
end