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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 36cc450006286215c770afb827d6eceed69ae22a8ad9c656e6a9b5c390725098
4
- data.tar.gz: 8a503fce6425578681ce03921242f3f189ca041d3bcdb518a209cf7b22b1ef86
3
+ metadata.gz: 62159f76d28951cd1318ee83403215626a3e6a094fcccaec0f67ab4865f50ce4
4
+ data.tar.gz: de18a9f234cacc5943468cc9454e8bb8102c3dac38a81129b0dc9cebc1820368
5
5
  SHA512:
6
- metadata.gz: 17f315d6f0a473ef646bfbbb0fc2728243c275a8f14a85b1ee2f905a70542fdea28d08c30aeadac4eb4d979095a85579bc4c6046de75556555307954ab98ce53
7
- data.tar.gz: 9c1af523d534885a18688acd8cd5304afa61551f104ad1650dc4a5558a04494341e8e33f44955fd4560d2a088333d8783577346d6a03fc0e92db4c319b7d3722
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
@@ -20,6 +20,6 @@
20
20
 
21
21
  module Async
22
22
  module HTTP
23
- VERSION = "0.27.2"
23
+ VERSION = "0.27.3"
24
24
  end
25
25
  end
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.2
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-28 00:00:00.000000000 Z
11
+ date: 2018-06-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: async