aboutsummaryrefslogtreecommitdiff
path: root/common/src/Common/Model
diff options
context:
space:
mode:
Diffstat (limited to 'common/src/Common/Model')
-rw-r--r--common/src/Common/Model/CreatePayment.hs3
-rw-r--r--common/src/Common/Model/InitResult.hs3
2 files changed, 4 insertions, 2 deletions
diff --git a/common/src/Common/Model/CreatePayment.hs b/common/src/Common/Model/CreatePayment.hs
index 8e2ab73..cd0b01d 100644
--- a/common/src/Common/Model/CreatePayment.hs
+++ b/common/src/Common/Model/CreatePayment.hs
@@ -2,7 +2,7 @@ module Common.Model.CreatePayment
( CreatePayment(..)
) where
-import Data.Aeson (FromJSON)
+import Data.Aeson (FromJSON, ToJSON)
import Data.Text (Text)
import Data.Time.Calendar (Day)
import GHC.Generics (Generic)
@@ -19,3 +19,4 @@ data CreatePayment = CreatePayment
} deriving (Show, Generic)
instance FromJSON CreatePayment
+instance ToJSON CreatePayment
diff --git a/common/src/Common/Model/InitResult.hs b/common/src/Common/Model/InitResult.hs
index 542e6c7..f4c08a9 100644
--- a/common/src/Common/Model/InitResult.hs
+++ b/common/src/Common/Model/InitResult.hs
@@ -10,7 +10,8 @@ import Common.Model.Init (Init)
data InitResult =
InitSuccess Init
- | InitEmpty (Either Text (Maybe Text))
+ | InitError Text
+ | InitEmpty
deriving (Show, Generic)
instance FromJSON InitResult