protocol-http 0.23.4 → 0.23.7

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: 0a90ddbbf77b6838a596c01ff6bc77d7f67867eb91cc3560d92da5458a011af9
4
- data.tar.gz: 803a2218c2d60270c8eca75f49d1063a1b61fd45d66a0313d6e20a0abf2d0587
3
+ metadata.gz: 3684eaed45be5b2982d7e66469f286d48ab654903603ec9067b9d4c5753e9426
4
+ data.tar.gz: 68af8b829774b8674a9892f7ae2174c272c1faac17b01906797310edc5067e5e
5
5
  SHA512:
6
- metadata.gz: 36f23a497f933e91cf8ca08e367faeaba6539fdafc86587aca27d0ad7e4f2c2d7fe4f3224f9f7509f07e5fdabf733a72c875a7cb2ba29d507b3dcba5b1af6777
7
- data.tar.gz: 056d805e7795929d8af1609e490bb4ff86b7c9e083c585ed08aee68ea810ba9fddcc3beceb1ec0102e245cbf6f2a2712c03bbf8d83a153b0eac4ce369ef4f54b
6
+ metadata.gz: a38afbc159583cbdb66c98b6bbfdce31b7fbe7280b232a17ea70879ec897bd8ee78330ecdebadaaf1053853bcc6bad2fb87fd7b4dc722a0fa25ba14c1f04158d
7
+ data.tar.gz: efe7d17b35892fcd393c6f47bc2845ff76144ad8d88d365d277969cc3f8fad87ed14e40b10d08bfc9857673a5e425613b3bc5c5d98f38d5c40698354b467b79b
checksums.yaml.gz.sig CHANGED
Binary file
@@ -68,7 +68,7 @@ module Protocol
68
68
  def self.parse(string)
69
69
  head, *directives = string.split(/\s*;\s*/)
70
70
 
71
- key, value = head.split('=')
71
+ key, value = head.split('=', 2)
72
72
  directives = self.parse_directives(directives)
73
73
 
74
74
  self.new(
@@ -20,7 +20,7 @@
20
20
  # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
21
  # THE SOFTWARE.
22
22
 
23
- require_relative '../headers'
23
+ require_relative '../middleware'
24
24
 
25
25
  module Protocol
26
26
  module HTTP
@@ -67,6 +67,15 @@ module Protocol
67
67
  Response[200, Headers['content-type' => 'text/plain'], ["Hello World!"]]
68
68
  end
69
69
  end
70
+
71
+ module NotFound
72
+ def self.close
73
+ end
74
+
75
+ def self.call(request)
76
+ Response[404, Headers[], []]
77
+ end
78
+ end
70
79
  end
71
80
  end
72
81
  end
@@ -33,7 +33,7 @@ module Protocol
33
33
  # Unescapes a percent encoded string.
34
34
  def self.unescape(string, encoding = string.encoding)
35
35
  string.b.gsub(/%(\h\h)/) do |hex|
36
- Integer(hex, 16).chr
36
+ Integer($1, 16).chr
37
37
  end.force_encoding(encoding)
38
38
  end
39
39
 
@@ -22,6 +22,6 @@
22
22
 
23
23
  module Protocol
24
24
  module HTTP
25
- VERSION = "0.23.4"
25
+ VERSION = "0.23.7"
26
26
  end
27
27
  end
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: protocol-http
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.23.4
4
+ version: 0.23.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Williams
@@ -41,7 +41,7 @@ cert_chain:
41
41
  Q2K9NVun/S785AP05vKkXZEFYxqG6EW012U4oLcFl5MySFajYXRYbuUpH6AY+HP8
42
42
  voD0MPg1DssDLKwXyt1eKD/+Fq0bFWhwVM/1XiAXL7lyYUyOq24KHgQ2Csg=
43
43
  -----END CERTIFICATE-----
44
- date: 2022-08-15 00:00:00.000000000 Z
44
+ date: 2022-08-26 00:00:00.000000000 Z
45
45
  dependencies:
46
46
  - !ruby/object:Gem::Dependency
47
47
  name: bundler
metadata.gz.sig CHANGED
Binary file