Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix generation of content types #9

Merged
merged 2 commits into from
Oct 6, 2015

Conversation

danielwhite
Copy link
Contributor

Currently static content is being assigned a Content-Type header of an empty string.

The index works out of the box correctly, but will misbehave if other middleware is added to the request handler.

This is necessary to support middleware that performs compression of the
response.
This has been setting the `Content-Type` header to an empty string,
because the `mime.TypeByExtension` function expects a string with a
leading dot.
@ian-kent
Copy link
Member

ian-kent commented Oct 6, 2015

👍 awesome, thanks @danielwhite

ian-kent added a commit that referenced this pull request Oct 6, 2015
@ian-kent ian-kent merged commit d78b1cc into mailhog:master Oct 6, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants