yesod-routes 1.2.0.5 → 1.2.0.6
raw patch · 3 files changed
+7/−1 lines, 3 files
Files
- Yesod/Routes/Parse.hs +1/−0
- test/Hierarchy.hs +5/−0
- yesod-routes.cabal +1/−1
Yesod/Routes/Parse.hs view
@@ -184,6 +184,7 @@ pieceFromString :: String -> Either String (CheckOverlap, Piece String) pieceFromString ('#':'!':x) = Right $ (False, Dynamic x)+pieceFromString ('!':'#':x) = Right $ (False, Dynamic x) -- https://github.com/yesodweb/yesod/issues/652 pieceFromString ('#':x) = Right $ (True, Dynamic x) pieceFromString ('*':x) = Left x pieceFromString ('+':x) = Left x
test/Hierarchy.hs view
@@ -77,6 +77,8 @@ let resources = [parseRoutes| / HomeR GET +/!#Int BackwardsR GET+ /admin/#Int AdminR: / AdminRootR GET /login LoginR GET POST@@ -140,6 +142,9 @@ getHomeR :: Handler site String getHomeR = "home"++getBackwardsR :: Int -> Handler site Text+getBackwardsR _ = pack "backwards" getAdminRootR :: Int -> Handler site Text getAdminRootR i = pack $ "admin root: " ++ show i
yesod-routes.cabal view
@@ -1,5 +1,5 @@ name: yesod-routes-version: 1.2.0.5+version: 1.2.0.6 license: MIT license-file: LICENSE author: Michael Snoyman <michael@snoyman.com>