From 47aeb20c4b4d809473a82e2b10f800b462a734bd Mon Sep 17 00:00:00 2001 From: "Julian K. Arni" Date: Sun, 19 Apr 2015 14:51:34 +0200 Subject: [PATCH] Fix mimeRender name change --- example/greet.hs | 2 +- test/Servant/DocsSpec.hs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/example/greet.hs b/example/greet.hs index e5734472..fc649607 100644 --- a/example/greet.hs +++ b/example/greet.hs @@ -27,7 +27,7 @@ instance ToJSON Greet -- | We can also implement 'MimeRender' for additional formats like 'PlainText'. instance MimeRender PlainText Greet where - toByteString Proxy (Greet s) = "\"" <> cs s <> "\"" + mimeRender Proxy (Greet s) = "\"" <> cs s <> "\"" -- We add some useful annotations to our captures, -- query parameters and request body to make the docs diff --git a/test/Servant/DocsSpec.hs b/test/Servant/DocsSpec.hs index bc8b75ab..803823ba 100644 --- a/test/Servant/DocsSpec.hs +++ b/test/Servant/DocsSpec.hs @@ -56,7 +56,7 @@ instance ToSample Int where toSample = Just 17 instance MimeRender PlainText Int where - toByteString _ = cs . show + mimeRender _ = cs . show type TestApi1 = Get '[JSON, PlainText] Int