servant-snap-0.8.1: A family of combinators for defining webservices APIs and serving them

Safe HaskellNone
LanguageHaskell2010

Servant.Server.Internal.PathInfo

Synopsis

Documentation

pathIsEmpty :: Request -> Bool Source #

Like `null . pathInfo`, but works with redundant trailing slashes.

processedPathInfo :: Request -> [Text] Source #

Returns a processed pathInfo from the request.

In order to handle matrix parameters in the request correctly, the raw pathInfo needs to be processed, so routing works as intended. Therefor this function should be used to access the pathInfo for routing purposes.