Skip to content

Unzipping response body only for statuses != 204#1129

Merged
emilyemorehouse merged 1 commit intoaxios:masterfrom
drawski:master
May 15, 2019
Merged

Unzipping response body only for statuses != 204#1129
emilyemorehouse merged 1 commit intoaxios:masterfrom
drawski:master

Conversation

@drawski
Copy link
Copy Markdown
Contributor

@drawski drawski commented Oct 13, 2017

Bugfix

When request has Content-Encoding: gzip|deflate|compress header and response has 204 No Content status code the following error is thrown: HttpClientError: unexpected end of file.

This pull request fixes the issue by calling stream = stream.pipe(zip.createUnzip()) for all status codes but 204.

@emilyemorehouse emilyemorehouse force-pushed the master branch 2 times, most recently from 2760755 to 48a7902 Compare February 19, 2018 23:22
Copy link
Copy Markdown

@OtacilioN OtacilioN left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can someone please approve this merge request ❤️ I am facing this issue right now

@antonmos
Copy link
Copy Markdown

Please merge this! this fixes #1658

@OtacilioN
Copy link
Copy Markdown

Hey @antonmos I saw that I received an Email from you, unfortunately, I am not maintainer of this repository and I can`t do this.

@emilyemorehouse emilyemorehouse merged commit fd0c959 into axios:master May 15, 2019
@dpopp07
Copy link
Copy Markdown

dpopp07 commented May 15, 2019

@emilyemorehouse thanks for merging this! When can we expect a release with this patch?

This is causing a production bug for me.

irembesik added a commit to irembesik/blockchain that referenced this pull request Oct 5, 2019
this update has an important change 
axios/axios#1129
@axios axios locked and limited conversation to collaborators May 3, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants