Fix OpenID 404 (thanks Blake)
This commit is contained in:
parent
22fbc23442
commit
5cedddb364
@ -26,7 +26,7 @@ authOpenId :: YesodAuth m => AuthPlugin m
|
|||||||
authOpenId =
|
authOpenId =
|
||||||
AuthPlugin "openid" dispatch login
|
AuthPlugin "openid" dispatch login
|
||||||
where
|
where
|
||||||
complete = PluginR "openid" ["complete", ""]
|
complete = PluginR "openid" ["complete"]
|
||||||
name = "openid_identifier"
|
name = "openid_identifier"
|
||||||
login tm = do
|
login tm = do
|
||||||
ident <- lift newIdent
|
ident <- lift newIdent
|
||||||
@ -71,10 +71,12 @@ authOpenId =
|
|||||||
toMaster <- getRouteToMaster
|
toMaster <- getRouteToMaster
|
||||||
setMessage $ messageNoOpenID y
|
setMessage $ messageNoOpenID y
|
||||||
redirect RedirectTemporary $ toMaster LoginR
|
redirect RedirectTemporary $ toMaster LoginR
|
||||||
dispatch "GET" ["complete", ""] = do
|
dispatch "GET" ["complete", ""] = dispatch "GET" ["complete"] -- compatibility issues
|
||||||
|
dispatch "GET" ["complete"] = do
|
||||||
rr <- getRequest
|
rr <- getRequest
|
||||||
completeHelper $ reqGetParams rr
|
completeHelper $ reqGetParams rr
|
||||||
dispatch "POST" ["complete", ""] = do
|
dispatch "POST" ["complete", ""] = dispatch "POST" ["complete"] -- compatibility issues
|
||||||
|
dispatch "POST" ["complete"] = do
|
||||||
(posts, _) <- runRequestBody
|
(posts, _) <- runRequestBody
|
||||||
completeHelper posts
|
completeHelper posts
|
||||||
dispatch _ _ = notFound
|
dispatch _ _ = notFound
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
name: yesod-auth
|
name: yesod-auth
|
||||||
version: 0.3.0
|
version: 0.3.0.1
|
||||||
license: BSD3
|
license: BSD3
|
||||||
license-file: LICENSE
|
license-file: LICENSE
|
||||||
author: Michael Snoyman, Patrick Brisbin
|
author: Michael Snoyman, Patrick Brisbin
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user