protocol-http 0.14.1 → 0.14.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1a8ecc7ff666bfe900451d95f8fb7fa40f67caa5ca686844b827c19729816693
4
- data.tar.gz: 4acbac83b751e2602479adc863c6b75f7bb2bba9bbe4dfc30a6151435c8f2ebe
3
+ metadata.gz: 79e99a9aa8c3de7389fdf856e4564e17a927928f942524c031b26e3ac17b5c13
4
+ data.tar.gz: c168521d98510634b9603295742bbc0133974630f7aa2c8d4149f23817307c17
5
5
  SHA512:
6
- metadata.gz: be4092bb56744f84e434cc8de3d3b7d7632cfdbe2d424e4153b5204cefd17bdf0cb64304070e5ed2f4070bab08d25cbb4e0ae04daad1157bb6cdc03da4b44385
7
- data.tar.gz: d1b4cdd713e5b03eba86c6c3ed63f5097eddc4e343d187cf2957378abfcb5094b103a2c3df6c19e3209afcafb7d3950eb4eb387400b548ad42da88a580ad7a5d
6
+ metadata.gz: 92a7c9200438bc1698cd7a25498b1ef90acefeba4599305c3110e6ab43356f895cdd61f661d7a1adc24abd3709ded22136e6f6b9f8494e317636155c71fba9c4
7
+ data.tar.gz: 6c3df29e2ec97504d273965bc0e8532f692a3aec405f518a4b8d9071b5f65664d3dd7c1c3f63ccbf3ead5bace750aae6ce26c6e127177692d9c9412ac07708bc
@@ -44,6 +44,8 @@ module Protocol
44
44
  else
45
45
  yield message, nil
46
46
  end
47
+
48
+ return message
47
49
  end
48
50
  end
49
51
  end
@@ -0,0 +1,40 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright, 2020, by Samuel G. D. Williams. <http://www.codeotaku.com>
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in
13
+ # all copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ # THE SOFTWARE.
22
+
23
+ require_relative 'split'
24
+
25
+ module Protocol
26
+ module HTTP
27
+ module Header
28
+ # Header value which is split by newline charaters (e.g. cookies).
29
+ class Vary < Split
30
+ def initialize(value)
31
+ super(value.downcase)
32
+ end
33
+
34
+ def << value
35
+ super(value.downcase)
36
+ end
37
+ end
38
+ end
39
+ end
40
+ end
@@ -25,6 +25,7 @@ require_relative 'header/multiple'
25
25
  require_relative 'header/cookie'
26
26
  require_relative 'header/connection'
27
27
  require_relative 'header/cache_control'
28
+ require_relative 'header/vary'
28
29
 
29
30
  module Protocol
30
31
  module HTTP
@@ -149,6 +150,7 @@ module Protocol
149
150
 
150
151
  'connection' => Header::Connection,
151
152
  'cache-control' => Header::CacheControl,
153
+ 'vary' => Header::Vary,
152
154
 
153
155
  # Headers specifically for proxies:
154
156
  'via' => Split,
@@ -22,6 +22,6 @@
22
22
 
23
23
  module Protocol
24
24
  module HTTP
25
- VERSION = "0.14.1"
25
+ VERSION = "0.14.2"
26
26
  end
27
27
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: protocol-http
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.14.1
4
+ version: 0.14.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Williams
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-03-06 00:00:00.000000000 Z
11
+ date: 2020-03-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: covered
@@ -102,6 +102,7 @@ files:
102
102
  - lib/protocol/http/header/cookie.rb
103
103
  - lib/protocol/http/header/multiple.rb
104
104
  - lib/protocol/http/header/split.rb
105
+ - lib/protocol/http/header/vary.rb
105
106
  - lib/protocol/http/headers.rb
106
107
  - lib/protocol/http/methods.rb
107
108
  - lib/protocol/http/middleware.rb