私はイェソドの私Handler
関数からByteString
を返すようにしようとしている:YesodのハンドラからByteStringを返すことができないのはなぜですか?
getHomeR :: Handler ByteString
getHomeR = return "foo"
が、私はこのエラーを取得しています:
/Users/maximiliantagher/Documents/Mercury/hs/mercury-web-backend/src/Application.hs:48:1: error:
• No instance for (ToTypedContent ByteString)
arising from a use of ‘yesodRunner’
• In the expression:
yesodRunner getHomeR env1404_axwe (Just HomeR) req1404_axwf
In a case alternative:
"GET"
-> yesodRunner getHomeR env1404_axwe (Just HomeR) req1404_axwf
In the expression:
case Network.Wai.Internal.requestMethod req1404_axwf of {
"GET"
-> yesodRunner getHomeR env1404_axwe (Just HomeR) req1404_axwf
_ -> yesodRunner
(void badMethod) env1404_axwe (Just HomeR) req1404_axwf }
なぜ、この出来事と、なぜByteString
が持っていないですa ToTypedContent
インスタンス?