fixing build_requests signatures, as 4 top parameters aren't supported, and one calls map although one expects #each

This commit is contained in:
HoneyryderChuck 2020-10-19 01:39:00 +01:00
parent cb4a30d7f3
commit 33487d03d5

View File

@ -135,10 +135,10 @@ module HTTPX
reqs.map do |verb, uri, opts = EMPTY_HASH|
build_request(verb, uri, request_options.merge(opts))
end
when 2, 3
when 2
verb, uris = args
if uris.respond_to?(:each)
uris.map do |uri, **opts|
uris.enum_for(:each).map do |uri, opts = EMPTY_HASH|
build_request(verb, uri, request_options.merge(opts))
end
else