Skip to content

fix(android): ignore gzip content-encoding for 204 status code#7417

Merged
manoldonev merged 2 commits into
NativeScript:masterfrom
lochstar:android-204-status-gzip-fix
Jun 28, 2019
Merged

fix(android): ignore gzip content-encoding for 204 status code#7417
manoldonev merged 2 commits into
NativeScript:masterfrom
lochstar:android-204-status-gzip-fix

Conversation

@lochstar

Copy link
Copy Markdown
Contributor

PR Checklist

What is the current behavior?

A HTTP request that responds with a 204: No Content status and has 'Content-Encoding': 'gzip' header set, throws a java.io.EOFException on Android. This results in the request failing with a null statusCode, null statusText and null headers. This doesn't occur on iOS.

What is the new behavior?

gzip encoding is ignored if the response status is 204. Response correctly resolves.

Fixes #7375.

@cla-bot cla-bot Bot added the cla: yes label Jun 28, 2019
@manoldonev

Copy link
Copy Markdown
Contributor

test

@manoldonev manoldonev changed the title fix(android): Ignore gzip Content-Encoding for 204 statusCode fix(android): ignore gzip content-encoding for 204 status code Jun 28, 2019
@manoldonev manoldonev merged commit 4437cd6 into NativeScript:master Jun 28, 2019
@lochstar lochstar deleted the android-204-status-gzip-fix branch July 10, 2019 22:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

204 rest api with content-type="application/json" throwing error

2 participants