From 88fc9feae7041abe871fcb781878993fd2709925 Mon Sep 17 00:00:00 2001 From: nek0 Date: Sun, 17 Aug 2014 23:00:35 +0200 Subject: [PATCH] token now deletes on activation --- Handler/Activate.hs | 1 + 1 file changed, 1 insertion(+) diff --git a/Handler/Activate.hs b/Handler/Activate.hs index b8b14fa..006771a 100644 --- a/Handler/Activate.hs +++ b/Handler/Activate.hs @@ -15,5 +15,6 @@ getActivateR token = do Just x -> do userId <- runDB $ insert $ tokenUser (entityVal x) liftIO $ createDirectoryIfMissing True $ "data" (unpack $ extractKey userId) + runDB $ delete (entityKey x) setMessage $ "User activated" redirect $ HomeR