mirror of
https://github.com/HoneyryderChuck/httpx.git
synced 2025-10-05 00:02:38 -04:00
parser is empty when there are no requests as well
This commit is contained in:
parent
88b2c9370c
commit
d9f2632a67
@ -26,7 +26,7 @@ module HTTPX
|
||||
def empty?
|
||||
# this means that for every request there's an available
|
||||
# partial response, so there are no in-flight requests waiting.
|
||||
@requests.any? { |request| request.response.nil? }
|
||||
@requests.empty? || @requests.any? { |request| request.response.nil? }
|
||||
end
|
||||
|
||||
def <<(data)
|
||||
|
Loading…
x
Reference in New Issue
Block a user