aboutsummaryrefslogtreecommitdiff
path: root/Server
diff options
context:
space:
mode:
Diffstat (limited to 'Server')
-rw-r--r--Server/Main.hs7
1 files changed, 5 insertions, 2 deletions
diff --git a/Server/Main.hs b/Server/Main.hs
index 8954d6d..bed3f82 100644
--- a/Server/Main.hs
+++ b/Server/Main.hs
@@ -8,6 +8,9 @@ import Network.Wai
import Network.HTTP.Types
import Network.Wai.Handler.Warp (run)
+headers :: ResponseHeaders
+headers = [("Content-Type", "text/html;charset=UTF-8")]
+
app :: Application
app request respond = respond $
case rawPathInfo request of
@@ -17,7 +20,7 @@ app request respond = respond $
index :: Response
index =
responseFile status200
- [("Content-Type", "text/html;charset=UTF-8")]
+ headers
"pages/index.html"
Nothing
@@ -28,7 +31,7 @@ index =
errorResponse :: Response
errorResponse =
responseFile status200
- [("Content-Type", "text/html;charset=UTF-8")]
+ headers
"pages/error.html"
Nothing