summaryrefslogtreecommitdiff
path: root/src/Language/GraphQL.hs
diff options
context:
space:
mode:
authorEugen Wissner <belka@caraus.de>2020-06-03 07:20:38 +0200
committerEugen Wissner <belka@caraus.de>2020-06-03 07:20:38 +0200
commit93a04032886976b540f5fdb1417bd085a642f772 (patch)
tree712dda8a81286e0e39719a25f798ce23bb574e69 /src/Language/GraphQL.hs
parentd12577ae717512979c7654191ca65f25fc877907 (diff)
downloadgraphql-93a04032886976b540f5fdb1417bd085a642f772.tar.gz
Resolve abstract types
Objects that can be a part of an union or interface should return __typename as string.
Diffstat (limited to 'src/Language/GraphQL.hs')
-rw-r--r--src/Language/GraphQL.hs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Language/GraphQL.hs b/src/Language/GraphQL.hs
index aef23f0..961253f 100644
--- a/src/Language/GraphQL.hs
+++ b/src/Language/GraphQL.hs
@@ -16,7 +16,7 @@ import Language.GraphQL.Type.Schema
import Text.Megaparsec (parse)
-- | If the text parses correctly as a @GraphQL@ query the query is
--- executed using the given 'Schema.Resolver's.
+-- executed using the given 'Schema'.
graphql :: Monad m
=> Schema m -- ^ Resolvers.
-> Text -- ^ Text representing a @GraphQL@ request document.
@@ -25,7 +25,7 @@ graphql = flip graphqlSubs (mempty :: Aeson.Object)
-- | If the text parses correctly as a @GraphQL@ query the substitution is
-- applied to the query and the query is then executed using to the given
--- 'Schema.Resolver's.
+-- 'Schema'.
graphqlSubs :: (Monad m, VariableValue a)
=> Schema m -- ^ Resolvers.
-> HashMap Name a -- ^ Variable substitution function.