lib/http/protocol/headers.rb in http-protocol-0.12.1 vs lib/http/protocol/headers.rb in http-protocol-0.12.2
- old
+ new
@@ -103,11 +103,11 @@
def include? key
self[key] != nil
end
def slice!(keys)
- values, @fields = @fields.partition do |field|
+ _, @fields = @fields.partition do |field|
keys.include?(field.first.downcase)
end
keys.each do |key|
@indexed.delete(key)
@@ -173,10 +173,10 @@
'proxy-authenticate' => Multiple
}.tap{|hash| hash.default = Split}
# Delete all headers with the given key, and return the merged value.
def delete(key)
- values, @fields = @fields.partition do |field|
+ _, @fields = @fields.partition do |field|
field.first.downcase == key
end
return @indexed.delete(key)
end