yesod-auth 1.4.4 → 1.4.5
raw patch · 4 files changed
+16/−4 lines, 4 files
Files
- ChangeLog.md +4/−0
- Yesod/Auth.hs +4/−0
- Yesod/Auth/Email.hs +7/−3
- yesod-auth.cabal +1/−1
ChangeLog.md view
@@ -1,3 +1,7 @@+## 1.4.5++* Adds export of email verify route [#980](https://github.com/yesodweb/yesod/pull/980)+ ## 1.4.4 * Add AuthenticationResult and authenticate function [#959](https://github.com/yesodweb/yesod/pull/959)
Yesod/Auth.hs view
@@ -146,6 +146,10 @@ authPlugins :: master -> [AuthPlugin master] -- | What to show on the login page.+ -- + -- Default handler concatenates plugin widgets and wraps the result+ -- in 'authLayout'. Override if you need fancy widget containers+ -- or entirely custom page. loginHandler :: AuthHandler master Html loginHandler = do tp <- getRouteToParent
Yesod/Auth/Email.hs view
@@ -30,6 +30,7 @@ , registerR , forgotPasswordR , setpassR+ , verifyR , isValidPass -- * Types , Email@@ -74,8 +75,11 @@ forgotPasswordR = PluginR "email" ["forgot-password"] setpassR = PluginR "email" ["set-password"] -verify :: Text -> Text -> AuthRoute -- FIXME-verify eid verkey = PluginR "email" ["verify", eid, verkey]+-- |+--+-- Since 1.4.5+verifyR :: Text -> Text -> AuthRoute -- FIXME+verifyR eid verkey = PluginR "email" ["verify", eid, verkey] type Email = Text type VerKey = Text@@ -345,7 +349,7 @@ Nothing -> loginErrorMessageI dest (Msg.IdentifierNotFound identifier) Just (lid, verKey, email) -> do render <- getUrlRender- let verUrl = render $ verify (toPathPiece lid) verKey+ let verUrl = render $ verifyR (toPathPiece lid) verKey lift $ sendVerifyEmail email verKey verUrl lift $ confirmationEmailSentResponse identifier
yesod-auth.cabal view
@@ -1,5 +1,5 @@ name: yesod-auth-version: 1.4.4+version: 1.4.5 license: MIT license-file: LICENSE author: Michael Snoyman, Patrick Brisbin