Skip to content
This repository has been archived by the owner on Jun 25, 2024. It is now read-only.

Removes body data from http 204 response #141

Merged
merged 1 commit into from
Jan 7, 2019
Merged

Removes body data from http 204 response #141

merged 1 commit into from
Jan 7, 2019

Conversation

ibesora
Copy link
Contributor

@ibesora ibesora commented Jan 7, 2019

The HTTP 1.1 specification states the following on the 204 No content status code definition:

The 204 response MUST NOT include a message-body, and thus is always
terminated by the first empty line after the header fields.

Some Vector Tile libraries (at least Mapbox GL Native and Mapbox GL React Native) throw an error if a body message is present on an HTTP response with the 204 status code. This PR removes the body message from the response when an HTTP 204 response is sent.

Note: This PR is the same as the one in tileserver-gl/pull/339 but with the changes done in tileserver.php

@daliborjanak daliborjanak self-assigned this Jan 7, 2019
@daliborjanak daliborjanak merged commit 287da50 into maptiler:master Jan 7, 2019
@daliborjanak
Copy link
Collaborator

Make sense. Thanks

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants