async-http 0.27.2 → 0.27.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/async/http/content_encoding.rb +3 -0
- data/lib/async/http/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 62159f76d28951cd1318ee83403215626a3e6a094fcccaec0f67ab4865f50ce4
|
4
|
+
data.tar.gz: de18a9f234cacc5943468cc9454e8bb8102c3dac38a81129b0dc9cebc1820368
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dd79c554a941ba4e0d33221c642a003b90c8459faf3a8a8c025fdeb9f5ef03db9f30f4ff37ce3b26511447b5b903c96783f8109b4689ba417779dccc3e0b5b20
|
7
|
+
data.tar.gz: e807c841615de91a7d97c20a47c80c1c9e30246980d1ff627f4c88486d147d8108e1d1cd953928b0a02e350fbc95a88e45c053e5601ad5625bc62de431b40981
|
@@ -43,6 +43,9 @@ module Async
|
|
43
43
|
def call(request)
|
44
44
|
response = super
|
45
45
|
|
46
|
+
# Early exit if the response has already specified a content-encoding.
|
47
|
+
return response if response.headers['content-encoding']
|
48
|
+
|
46
49
|
# TODO use http-accept and sort by priority
|
47
50
|
if !response.body.empty? and accept_encoding = request.headers['accept-encoding']
|
48
51
|
if content_type = response.headers['content-type'] and @content_types =~ content_type
|
data/lib/async/http/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: async-http
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.27.
|
4
|
+
version: 0.27.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Samuel Williams
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-06-
|
11
|
+
date: 2018-06-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: async
|