summaryrefslogtreecommitdiff
path: root/Auth/Proxied.hs
diff options
context:
space:
mode:
authorClint Adams <clint@softwarefreedom.org>2013-10-24 15:34:15 -0400
committerClint Adams <clint@softwarefreedom.org>2013-10-24 17:39:13 -0400
commit515338784b8fc2fb5435ee4e061c092ff754d6cf (patch)
treeceb2c2660cacaa3b90a80836a9f1e0dd8941ffa2 /Auth/Proxied.hs
parent1725e252b7bd6bec9faecb0249961343bb27afb0 (diff)
Use newer persistent and newer Yesod
Diffstat (limited to 'Auth/Proxied.hs')
-rw-r--r--Auth/Proxied.hs8
1 files changed, 4 insertions, 4 deletions
diff --git a/Auth/Proxied.hs b/Auth/Proxied.hs
index 9e15de3..15f5808 100644
--- a/Auth/Proxied.hs
+++ b/Auth/Proxied.hs
@@ -6,11 +6,11 @@ module Auth.Proxied
) where
import Yesod.Auth
-import Yesod.Handler (notFound)
+import Yesod.Core (lift)
+import Yesod.Core.Handler (notFound, waiRequest)
import Text.Hamlet (hamlet)
-import Yesod.Widget (toWidget)
+import Yesod.Core.Widget (toWidget)
-import Yesod.Handler (waiRequest)
import Data.List (lookup)
import Data.Maybe (fromMaybe)
import Network.Wai (Request(requestHeaders))
@@ -27,7 +27,7 @@ authProxied =
where
dispatch _ [] = do
mfu <- fmap ((fmap (decodeUtf8 . B.takeWhile (58 /=)) . either (const Nothing) return . Base64.decode . B.drop 1 . B.dropWhile (32 /=) =<<) . lookup (mk "Authorization") . requestHeaders) waiRequest
- setCreds True $ Creds "proxied" (fromMaybe "" mfu) []
+ lift $ setCreds True $ Creds "proxied" (fromMaybe "" mfu) []
dispatch _ _ = notFound
login authToMaster =
let url = authToMaster (PluginR "proxied" []) in