wai-extra 0.1.2 → 0.1.2.1
raw patch · 2 files changed
+12/−8 lines, 2 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- Network/Wai/Parse.hs +11/−7
- wai-extra.cabal +1/−1
Network/Wai/Parse.hs view
@@ -52,14 +52,18 @@ -- * Percent decoding errors are ignored. In particular, "%Q" will be output as -- "%Q". parseQueryString :: S.ByteString -> [(S.ByteString, S.ByteString)]-parseQueryString q | S.null q = []-parseQueryString q =- let (x, xs) = breakDiscard 38 q -- ampersand- in parsePair x : parseQueryString xs+parseQueryString = parseQueryString' . dropQuestion where- parsePair x =- let (k, v) = breakDiscard 61 x -- equal sign- in (qsDecode k, qsDecode v)+ dropQuestion q | S.null q || S.head q /= 63 = q+ dropQuestion q | otherwise = S.tail q+ parseQueryString' q | S.null q = []+ parseQueryString' q =+ let (x, xs) = breakDiscard 38 q -- ampersand+ in parsePair x : parseQueryString' xs+ where+ parsePair x =+ let (k, v) = breakDiscard 61 x -- equal sign+ in (qsDecode k, qsDecode v) qsDecode :: S.ByteString -> S.ByteString
wai-extra.cabal view
@@ -1,5 +1,5 @@ Name: wai-extra-Version: 0.1.2+Version: 0.1.2.1 Synopsis: Provides some basic WAI handlers and middleware. Description: The goal here is to provide common features without many dependencies. License: BSD3