diff options
author | Igor Pashev <pashev.igor@gmail.com> | 2016-06-19 01:07:56 +0800 |
---|---|---|
committer | Igor Pashev <pashev.igor@gmail.com> | 2016-06-19 01:07:56 +0800 |
commit | 2b6f15ec6c1cca5c55ab73de82fb0badf42f357c (patch) | |
tree | 9f1136239df224cdf9703f7de03dba2fd6cc8fa1 /src/Application.hs | |
parent | c352f188b550d684b586c1dfbc608ee25f75cd41 (diff) | |
download | juandelacosa-2b6f15ec6c1cca5c55ab73de82fb0badf42f357c.tar.gz |
Do not serve /index.html
Diffstat (limited to 'src/Application.hs')
-rw-r--r-- | src/Application.hs | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/Application.hs b/src/Application.hs index 616532c..efcdbd2 100644 --- a/src/Application.hs +++ b/src/Application.hs @@ -36,14 +36,10 @@ app p f = do juanDeLaCosa :: Pool Connection -> Middleware -> FilePath -> ScottyM () juanDeLaCosa p logger dataDir = do - let - index_html = dataDir ++ "/" ++ "index.html" - middleware logger middleware $ staticPolicy (hasPrefix "static" >-> addBase dataDir) - get "/" $ file index_html - get "/index.html" $ file index_html + get "/" $ file (dataDir ++ "/" ++ "index.html") post "/resetMyPassword" $ apiResetMyPassword p get "/whoAmI" $ apiWhoAmI p |