From a0cd0b5008a15ce9e313398b0d48365eec15e74a Mon Sep 17 00:00:00 2001 From: Michael Snoyman Date: Wed, 17 Feb 2010 14:32:38 +0200 Subject: [PATCH] Removed ParamType --- Yesod/Request.hs | 4 ++-- Yesod/Response.hs | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Yesod/Request.hs b/Yesod/Request.hs index 1c455faa..589aaeb8 100644 --- a/Yesod/Request.hs +++ b/Yesod/Request.hs @@ -29,9 +29,9 @@ module Yesod.Request , languages , parseWaiRequest -- * Parameter - , ParamType (..) , ParamName , ParamValue + , ParamError #if TEST , testSuite #endif @@ -56,9 +56,9 @@ import Test.Framework (testGroup, Test) --import Test.HUnit hiding (Test) #endif -data ParamType = GetParam | PostParam type ParamName = String type ParamValue = String +type ParamError = String class RequestReader m where getRawRequest :: m RawRequest diff --git a/Yesod/Response.hs b/Yesod/Response.hs index 6c5a5726..085cc6b2 100644 --- a/Yesod/Response.hs +++ b/Yesod/Response.hs @@ -65,6 +65,7 @@ import qualified Data.Text.Lazy.Encoding as DTLE import Web.Encodings (formatW3) import qualified Network.Wai as W import qualified Network.Wai.Enumerator as WE +import Yesod.Request #if TEST import Data.Object.Html hiding (testSuite) @@ -192,7 +193,7 @@ data SpecialResponse = data ErrorResponse = NotFound | InternalError String - | InvalidArgs [(String, String)] -- FIXME use SomeException? + | InvalidArgs [(ParamName, ParamError)] | PermissionDenied deriving (Show, Eq)