From 459e10976910c09063af714f13e7ddbc89369e74 Mon Sep 17 00:00:00 2001 From: Ian Fabs Date: Mon, 26 Aug 2019 18:48:55 -0400 Subject: [PATCH] Update apollo-server.md (#3169) Example code on the rootValue field was incorrect --- docs/source/api/apollo-server.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/source/api/apollo-server.md b/docs/source/api/apollo-server.md index aa28b983881..66f379c02cd 100644 --- a/docs/source/api/apollo-server.md +++ b/docs/source/api/apollo-server.md @@ -61,10 +61,10 @@ new ApolloServer({ new ApolloServer({ typeDefs, resolvers, - rootValue: (documentAST) => ({ + rootValue: (documentAST) => { const op = getOperationAST(documentNode) return op === 'mutation' ? mutationRoot : queryRoot; - }) + } }); ```