From 79dcb7ee7425addb5b762b57b9accbd908bf7273 Mon Sep 17 00:00:00 2001 From: allen joslin Date: Sun, 9 Feb 2020 17:34:56 -0500 Subject: [PATCH 1/2] merge @williampaulo commit: Add header json response this pull request merges @williampaulo commit: Add header json response also updates the version number, beyond @supertowers bump for commit #09dbccd --- src/ApolloServer/index.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/ApolloServer/index.js b/src/ApolloServer/index.js index cdbae8e..343eedd 100644 --- a/src/ApolloServer/index.js +++ b/src/ApolloServer/index.js @@ -23,7 +23,9 @@ class ApolloServer { options: options, query: request.method() === 'POST' ? request.post() : request.get() }).then((gqlResponse) => { - return response.json(gqlResponse) + return response + .header("content-type", "application/json") + .send(gqlResponse) }, error => { if ('HttpQueryError' !== error.name) { throw error From c2d9a143d988524383f6da799c43b3da5cbc208e Mon Sep 17 00:00:00 2001 From: allen joslin Date: Sun, 9 Feb 2020 17:38:48 -0500 Subject: [PATCH 2/2] Update package.json --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 3d466e9..30996e1 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "adonis-apollo-server", - "version": "1.0.2", + "version": "1.0.4", "description": "Production-ready Node.js GraphQL server for AdonisJS", "main": "index.js", "scripts": {