Switch to BrowserId/GoogleEmail for scaffolded site
This commit is contained in:
parent
16da67f87f
commit
13e1179409
@ -41,7 +41,7 @@ authGoogleEmail =
|
||||
[whamlet|
|
||||
<form method=get action=@{tm forwardUrl}>
|
||||
<input type=hidden name=openid_identifier value=https://www.google.com/accounts/o8/id>
|
||||
<input type=submit value=_{Msg.LoginTitle}>
|
||||
<input type=submit value=_{Msg.LoginGoogle}>
|
||||
|]
|
||||
dispatch "GET" ["forward"] = do
|
||||
roid <- runInputGet $ iopt textField name
|
||||
|
||||
@ -20,7 +20,8 @@ import Yesod
|
||||
import Yesod.Static (Static, base64md5, StaticRoute(..))
|
||||
import Settings.StaticFiles
|
||||
import Yesod.Auth
|
||||
import Yesod.Auth.OpenId
|
||||
import Yesod.Auth.BrowserId
|
||||
import Yesod.Auth.GoogleEmail
|
||||
import Yesod.Default.Config
|
||||
import Yesod.Default.Util (addStaticContentExternal)
|
||||
import Yesod.Logger (Logger, logMsg, formatLogText)
|
||||
@ -144,7 +145,7 @@ instance YesodAuth ~sitearg~ where
|
||||
fmap Just $ insert $ User (credsIdent creds) Nothing
|
||||
|
||||
-- You can add other plugins like BrowserID, email or OAuth here
|
||||
authPlugins = [authOpenId]
|
||||
authPlugins = [authBrowserId, authGoogleEmail]
|
||||
|
||||
-- Sends off your mail. Requires sendmail in production!
|
||||
deliver :: ~sitearg~ -> L.ByteString -> IO ()
|
||||
|
||||
Loading…
Reference in New Issue
Block a user