on master help sign in
wai-extra: do not compress text/event-stream by default
commit79851df2867f2c85386807fe4c33ff483f3592af authorMichael Snoyman <michael@snoyman.com> dateTue 24 Jan 2012, 09:28 (15 years ago) parentf01d073
2 files changed+3−2
wai-extra/Network/Wai/Middleware/Gzip.hs+2−1 wai-extra/wai-extra.cabal+1−1
wai-extra/Network/Wai/Middleware/Gzip.hs+2−1
@@ -51,7 +51,8 @@ instance Default GzipSettings where
5151 def = GzipSettings GzipIgnore defaultCheckMime
5252
5353defaultCheckMime :: S.ByteString -> Bool
54−defaultCheckMime = S8.isPrefixOf "text/"
54+defaultCheckMime "text/event-stream" = False
55+defaultCheckMime bs = S8.isPrefixOf "text/" bs
5556
5657-- | Use gzip to compress the body of the response.
5758--
wai-extra/wai-extra.cabal+1−1
@@ -1,5 +1,5 @@
11Name: wai-extra
2−Version: 1.0.0
2+Version: 1.0.0.1
33Synopsis: Provides some basic WAI handlers and middleware.
44Description: The goal here is to provide common features without many dependencies.
55License: BSD3