about summary refs log tree commit diff
path: root/src/Main.hs
diff options
context:
space:
mode:
authorVincent Ambo <v.ambo@me.com>2012-03-18T22·23+0100
committerVincent Ambo <v.ambo@me.com>2012-03-18T22·23+0100
commitb7e34eba74918c04ab247ba7d761ddc3e6c46321 (patch)
treea3b65a39341eec7dad0fa944d481cdf2979ec606 /src/Main.hs
parentb8a045d163a50c138bfe6300fc39b5cddc40f5d1 (diff)
* changed entryEscape
Diffstat (limited to 'src/Main.hs')
-rw-r--r--src/Main.hs5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Main.hs b/src/Main.hs
index 8adef253a5..84fa0d9dd3 100644
--- a/src/Main.hs
+++ b/src/Main.hs
@@ -161,7 +161,10 @@ postEntry acid = do
     getLang "en" = return EN
 
 entryEscape :: Text -> Text
-entryEscape = T.replace "\n" "<br>"
+entryEscape = newlineEscape . newlineRNEscape
+  where
+    newlineEscape = T.replace "\n" "<br>"
+    newlineRNEscape = T.replace "\r\n" "<br>"
 
 entryList :: AcidState Blog -> BlogLang -> ServerPart Response
 entryList acid lang = do