From 3b7362861d443488d7de1978d9c5900eabf942e2 Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Fri, 3 Apr 2009 11:19:04 +0000 Subject: [PATCH] make the web server handle the null path --- WebCommand.hs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/WebCommand.hs b/WebCommand.hs index 0ba797773..7a17eddec 100644 --- a/WebCommand.hs +++ b/WebCommand.hs @@ -50,7 +50,9 @@ web opts args l = where handlers :: ServerPartT IO Response handlers = msum - [dir "print" $ withDataFn (look "a") $ \a -> templatise $ printreport [a] + [methodSP GET $ withDataFn (look "a") $ \a -> templatise $ balancereport [a] + ,methodSP GET $ templatise $ balancereport [] + ,dir "print" $ withDataFn (look "a") $ \a -> templatise $ printreport [a] ,dir "print" $ templatise $ printreport [] ,dir "register" $ withDataFn (look "a") $ \a -> templatise $ registerreport [a] ,dir "register" $ templatise $ registerreport []