@@ 23,11 23,11 @@ import Data.List as L
import Control.Monad (forM, void, when)
import Text.Read (readMaybe)
-strip = C.dropWhile isSpace -- FIXME Upgrade bytestring dependency for a real strip function.
+stripBS = C.dropWhile isSpace -- FIXME Upgrade bytestring dependency for a real strip function.
httpCacheDirective :: Response b -> Strict.ByteString -> Maybe Strict.ByteString
httpCacheDirective response key | Just header <- lookup hCacheControl $ responseHeaders response =
- let directives = Prelude.map strip $ C.split ',' header
+ let directives = Prelude.map stripBS $ C.split ',' header
in if key `Prelude.elem` directives
then Just ""
else listToMaybe $ mapMaybe (C.stripPrefix $ C.snoc key '=') directives