wai-extra-3.0.26.1: Provides some basic WAI handlers and middleware.

Safe Haskell | None
Language | Haskell2010

Network.Wai.Middleware.StripHeaders

Synopsis

- stripHeader :: ByteString -> Response -> Response
- stripHeaders :: [ByteString] -> Response -> Response
- stripHeaderIf :: ByteString -> (Request -> Bool) -> Middleware
- stripHeadersIf :: [ByteString] -> (Request -> Bool) -> Middleware

# Documentation

stripHeader :: ByteString -> Response -> Response Source #

stripHeaders :: [ByteString] -> Response -> Response Source #

stripHeaderIf :: ByteString -> (Request -> Bool) -> Middleware Source #

If the request satisifes the provided predicate, strip headers matching the provided header name.

Since 3.0.8

stripHeadersIf :: [ByteString] -> (Request -> Bool) -> Middleware Source #

If the request satisifes the provided predicate, strip all headers whose header name is in the list of provided header names.

Since 3.0.8