Skip to content

Commit 1c67f61

Browse files
committed
Documentation.
1 parent cfccf91 commit 1c67f61

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

lib/protocol/http/accept_encoding.rb

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,11 +49,10 @@ def call(request)
4949

5050
if body = response.body and !body.empty?
5151
if content_encoding = response.headers[CONTENT_ENCODING]
52-
# Process encodings from the end (last applied first)
53-
# Remove encodings as we successfully decode them
52+
# Process encodings in reverse order and remove them when they are decoded:
5453
while name = content_encoding.last
55-
# Look up wrapper with case-insensitive matching
56-
wrapper = @wrappers[name] || @wrappers[name.downcase]
54+
# Look up wrapper with case-insensitive matching:
55+
wrapper = @wrappers[name.downcase]
5756

5857
if wrapper
5958
body = wrapper.call(body)

0 commit comments

Comments
 (0)