Approot used in rpxnow login

This commit is contained in:
Michael Snoyman 2010-01-06 21:27:56 +02:00
parent 12a43ef90b
commit aff7722e12
2 changed files with 4 additions and 2 deletions

1
TODO
View File

@ -3,3 +3,4 @@ Cleanup Parameter stuff. Own module? Interface with formlets?
Authentication via e-mail address built in. (eaut.org)
OpenID 2 stuff (for direct Google login).
Languages (read languages header, set language cookie)
Approot and trailing slash missing

View File

@ -129,6 +129,7 @@ authOpenidComplete = do
rpxnowLogin :: YesodAuth y => Handler y HtmlObject
rpxnowLogin = do
ay <- getYesod
let (Approot ar) = approot ay
apiKey <- case rpxnowApiKey ay of
Just x -> return x
Nothing -> notFound
@ -138,8 +139,8 @@ rpxnowLogin = do
Nothing -> runRequest $ getParam "dest"
Just d -> return d
let dest = case dest' of
Nothing -> "/"
Just "" -> "/"
Nothing -> ar
Just "" -> ar
Just ('#':rest) -> rest
Just s -> s
ident <- Rpxnow.authenticate apiKey token