about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorVincent Ambo <v.ambo@me.com>2012-03-20T17·01+0100
committerVincent Ambo <v.ambo@me.com>2012-03-20T17·01+0100
commited05e92669a62b8d7b84f1ef334cbd2f44d6a776 (patch)
treed766d7cfb726c4b8e26d829267d53eef23e92ddd /src
parent877a7f84b04e424ffe04e4d0eee889890454978c (diff)
* gzip compression for dynamic files
Diffstat (limited to 'src')
-rw-r--r--src/Main.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Main.hs b/src/Main.hs
index d376f9ef0995..f0c28b9b5bd2 100644
--- a/src/Main.hs
+++ b/src/Main.hs
@@ -23,6 +23,7 @@ import qualified Data.Text as T
 import           Data.Time
 import           Data.SafeCopy (base, deriveSafeCopy)
 import           Happstack.Server hiding (Session)
+import           Happstack.Server.Compression
 import           System.Environment(getEnv)
 import           System.Locale (defaultTimeLocale)
 
@@ -44,7 +45,8 @@ main = do
             (\acid -> simpleHTTP nullConf {port = 80} $ tazBlog acid)
 
 tazBlog :: AcidState Blog -> ServerPart Response
-tazBlog acid =
+tazBlog acid = do
+    compr <- compressedResponseFilter
     msum [ dir (show DE) $ blogHandler acid DE
          , dir (show EN) $ blogHandler acid EN
          , do nullDir