We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e49c182 commit 7e2d56cCopy full SHA for 7e2d56c
lib/protocol/http/header/split.rb
@@ -17,10 +17,13 @@ class Split < Array
17
#
18
# @parameter value [String | Nil] the raw header value containing multiple entries separated by commas, or `nil` for an empty header.
19
def initialize(value = nil)
20
- if value
+ case value
21
+ when String
22
super(value.split(COMMA))
23
+ when nil
24
+ super()
25
else
- super()
26
+ super([value.to_s])
27
end
28
29
0 commit comments