diff options
author | Joris | 2015-12-29 22:38:42 +0100 |
---|---|---|
committer | Joris | 2015-12-29 22:38:42 +0100 |
commit | a7db22556b91bc7c499e010b4c051f4442ad8ce2 (patch) | |
tree | 9f991523cee681bf179c191260b95672f1c44def /src/server/Secure.hs | |
parent | c79fa3e212e8bb49f950da3c3218e32e3b9df2ec (diff) |
Using persona to validate emails
Diffstat (limited to 'src/server/Secure.hs')
-rw-r--r-- | src/server/Secure.hs | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/server/Secure.hs b/src/server/Secure.hs index 192fa10..7b6e6de 100644 --- a/src/server/Secure.hs +++ b/src/server/Secure.hs @@ -12,7 +12,7 @@ import Network.HTTP.Types.Status (forbidden403) import Database.Persist (Entity, entityVal) import Model.User (getUser) -import Model.SignIn (getSignInToken, isLastValidToken) +import Model.SignIn (getSignInToken) import Model.Database import Control.Monad.IO.Class (liftIO) @@ -44,9 +44,6 @@ getUserFromToken token = do mbSignIn <- fmap entityVal <$> getSignInToken token case mbSignIn of Just signIn -> do - isValid <- isLastValidToken signIn - if isValid - then getUser (signInEmail signIn) - else return Nothing + getUser (signInEmail signIn) Nothing -> return Nothing |