mirror of
https://github.com/HoneyryderChuck/httpx.git
synced 2025-10-04 00:00:37 -04:00
new rubocop, new needless linting...
This commit is contained in:
parent
9bab254710
commit
7a1cdd2c3d
@ -71,7 +71,7 @@ module HTTPX
|
||||
|
||||
return super unless option
|
||||
|
||||
with(option.to_sym => (args.first || options))
|
||||
with(option.to_sym => args.first || options)
|
||||
end
|
||||
|
||||
def respond_to_missing?(meth, *)
|
||||
|
@ -55,7 +55,7 @@ module HTTPX
|
||||
return :w
|
||||
end
|
||||
|
||||
unless (@connection.state == :connected && @handshake_completed)
|
||||
unless @connection.state == :connected && @handshake_completed
|
||||
return @buffer.empty? ? :r : :rw
|
||||
end
|
||||
|
||||
|
@ -236,9 +236,8 @@ module HTTPX
|
||||
end
|
||||
|
||||
def send(request)
|
||||
return super unless (
|
||||
return super unless
|
||||
@options.proxy && @state != :idle && connecting?
|
||||
)
|
||||
|
||||
(@proxy_pending ||= []) << request
|
||||
end
|
||||
|
@ -5,7 +5,7 @@ module HTTPX
|
||||
module_function
|
||||
|
||||
def normalize_keys(key, value, cond = nil, &block)
|
||||
if (cond && cond.call(value))
|
||||
if cond && cond.call(value)
|
||||
block.call(key.to_s, value)
|
||||
elsif value.respond_to?(:to_ary)
|
||||
if value.empty?
|
||||
|
@ -54,7 +54,7 @@ module ProfilerHelpers
|
||||
|
||||
next_memsize = obj_memsize_proc.call
|
||||
|
||||
next_memsize.each do |klass, (count, size)|
|
||||
next_memsize.each_key do |klass|
|
||||
prev_count, prev_size = prev_memsize[klass]
|
||||
current_count = count - prev_count
|
||||
next if current_count.zero?
|
||||
|
Loading…
x
Reference in New Issue
Block a user