aboutsummaryrefslogtreecommitdiff
path: root/src/server/View
diff options
context:
space:
mode:
Diffstat (limited to 'src/server/View')
-rw-r--r--src/server/View/Mail/SignIn.hs24
1 files changed, 1 insertions, 23 deletions
diff --git a/src/server/View/Mail/SignIn.hs b/src/server/View/Mail/SignIn.hs
index fc73dae..dca261d 100644
--- a/src/server/View/Mail/SignIn.hs
+++ b/src/server/View/Mail/SignIn.hs
@@ -8,10 +8,6 @@ import Data.Text (Text)
import qualified Data.Text.Lazy as LT
import Data.Text.Lazy.Builder (toLazyText, fromText)
-import Text.Blaze.Html
-import Text.Blaze.Html5
-import Text.Blaze.Html.Renderer.Text (renderHtml)
-
import Model.Database (User(..))
import qualified Model.Mail as M
import Model.Message.Key
@@ -24,28 +20,10 @@ getMail user url to =
, M.to = to
, M.subject = (getMessage SignInMailTitle)
, M.plainBody = plainBody user url
- , M.htmlBody = htmlBody user url
}
plainBody :: User -> Text -> LT.Text
-plainBody user url =
- LT.intercalate
- "\n"
- [ strictToLazy (getParamMessage [userName user] HiMail)
- , ""
- , strictToLazy (getMessage SignInLinkMail)
- , strictToLazy url
- ]
-
-htmlBody :: User -> Text -> LT.Text
-htmlBody user url =
- renderHtml . docTypeHtml . body $ do
- toHtml $ strictToLazy (getParamMessage [userName user] HiMail)
- br
- br
- toHtml $ strictToLazy (getMessage SignInLinkMail)
- br
- toHtml url
+plainBody user url = strictToLazy (getParamMessage [userName user, url] SignInMail)
strictToLazy :: Text -> LT.Text
strictToLazy = toLazyText . fromText