From 29c445093ed2d982730b4f7cd8620f27d827aefe Mon Sep 17 00:00:00 2001 From: Nickolay Kudasov Date: Wed, 20 Jan 2016 19:05:32 +0300 Subject: [PATCH] Fix servant-examples --- servant-examples/auth-combinator/auth-combinator.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/servant-examples/auth-combinator/auth-combinator.hs b/servant-examples/auth-combinator/auth-combinator.hs index ec152782..57ad36c4 100644 --- a/servant-examples/auth-combinator/auth-combinator.hs +++ b/servant-examples/auth-combinator/auth-combinator.hs @@ -29,7 +29,7 @@ instance HasServer rest => HasServer (AuthProtected :> rest) where type ServerT (AuthProtected :> rest) m = ServerT rest m route Proxy subserver = WithRequest $ \ request -> - route (Proxy :: Proxy rest) $ addAcceptCheck subserver $ cookieCheck request + (request, route (Proxy :: Proxy rest) $ addAcceptCheck subserver $ cookieCheck request) where cookieCheck req = case lookup "Cookie" (requestHeaders req) of Nothing -> return $ FailFatal err401 { errBody = "Missing auth header" }