Skip to content

Conversation

@bsara
Copy link
Contributor

@bsara bsara commented Mar 8, 2019

In the official GraphQL spec, it says the following:

When errors is present in the response, it may be helpful for it to appear first when serialized to make it more clear when errors are present in a response during debugging.

In my own personal debugging, I've found that my teammates and I often overlook errors because the property is located after data. The same goes for extensions. This pull request changes the response message property order to the following:

  • errors
  • extensions
  • data
… the following order: errors, extensions, data (this is as recommended by the GraphQL spec)
@oliemansm oliemansm merged commit 40ea03c into graphql-java-kickstart:master Mar 23, 2019
@oliemansm
Copy link
Member

@bsara Thanks for the contribution!

@bsara
Copy link
Contributor Author

bsara commented Mar 25, 2019

@oliemansm thanks!

@bsara bsara deleted the json-property-order branch March 25, 2019 22:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants