@@ -17,11 +17,6 @@ data User = User
1717 , registration_date :: Day
1818 } deriving (Eq, Show, Generic)
1919
20−-- orphan ToJSON instance for Day. necessary to derive one for User
21−instance ToJSON Day where
22− -- display a day in YYYY-mm-dd format
23− toJSON d = toJSON (showGregorian d)
24−
2520instance ToJSON User
2621
2722type UserAPI = "users" :> Get '[JSON] [User]