ring-clojure / ring

Clojure HTTP server abstraction
MIT License
3.75k stars 519 forks source link

Fix woff font file mime-type, add woff2 #421

Closed rgm closed 3 years ago

rgm commented 3 years ago

The mime types for WOFF fonts have been standardized and extended in RFC 8081. Per RFC 8081 § 4.4.5, the old application/font-woff should be replaced with font/woff.

Ring didn't previously have a definition for WOFF2. This commit adds it per RFC 8081 § 4.4.6. Including it allows Ring to properly auto-assign content type for files with a .woff2 extension on disk. These are currently going out as a blank content type by default.

atomist[bot] commented 3 years ago

Commit messages of this repository should follow the seven rules of a great Git commit message, as mentioned in the project's contributing guidelines. It looks like there's a few issues with the commit messages in this pull request:

atomist[bot] commented 3 years ago

Commit messages of this repository should follow the seven rules of a great Git commit message, as mentioned in the project's contributing guidelines. It looks like there's a few issues with the commit messages in this pull request:

weavejester commented 3 years ago

Thanks for the patch. Can you split this into two commits?

atomist[bot] commented 3 years ago

Commit messages of this repository should follow the seven rules of a great Git commit message, as mentioned in the project's contributing guidelines. It looks like there's a few issues with the commit messages in this pull request:

atomist[bot] commented 3 years ago

Commit messages of this repository should follow the seven rules of a great Git commit message, as mentioned in the project's contributing guidelines. It looks like there's a few issues with the commit messages in this pull request:

weavejester commented 3 years ago

Thanks for the commits. Could you cut down the second commit message to just:

Add woff2 font file mime-type

See https://tools.ietf.org/html/rfc8081#section-4.4.6

The rest of the commit message doesn't add any more information.

rgm commented 3 years ago

@weavejester need anything more here?

weavejester commented 3 years ago

I'm not notified about new commits on a PR unless a review is requested or a comment is made. The updates look fine, though.