lib/taric/configuration.rb in taric-0.3.4 vs lib/taric/configuration.rb in taric-0.4.0
- old
+ new
@@ -5,18 +5,18 @@
DEFAULT_REQUESTOR = -> connection, url {
connection.get url
}.curry
DEFAULT_RESPONSE_HANDLER = -> response {
- response.body
+ response
}
PARALLEL_REQUESTOR = -> connection, urls {
urls.map{|url| connection.get url}
}.curry
PARALLEL_RESPONSE_HANDLER = -> responses {
- responses.map{|response| {body: response.body, status: response.status}}
+ responses.map{|response| response}
}
def initialize(options = {})
@api_key = options.fetch(:api_key, ENV.fetch('RIOT_API_KEY'.freeze, nil))
@format = options.fetch(:format, :json)
\ No newline at end of file