@@ -42,6 +42,7 @@ import Data.Function (fix)
4242import Control.Exception (throwIO)
4343import qualified System.IO as IO
4444import Data.ByteString.Lazy.Internal (defaultChunkSize)
45+import Data.Word8 (_semicolon)
4546
4647data GzipSettings = GzipSettings
4748 { gzipFiles :: GzipFiles
@@ -58,7 +59,7 @@ defaultCheckMime :: S.ByteString -> Bool
5859defaultCheckMime bs =
5960 S8.isPrefixOf "text/" bs || bs' `Set.member` toCompress
6061 where
61− bs' = fst $ S.breakByte 59 bs -- semicolon
62+ bs' = fst $ S.break (== _semicolon) bs
6263 toCompress = Set.fromList
6364 [ "application/json"
6465 , "application/javascript"