Skip to content

Conversation

@WindomZ
Copy link
Contributor

@WindomZ WindomZ commented Jul 18, 2017

In examples,
if the query(RawQuery) values does not contain the key "query":

  1. Use r.URL.Query()["query"][0], throws runtime error: index out of range.
  2. Use r.URL.Query().Get("query"), gets the graphql.Result.Errors string such as [Must provide an operation.]. Maybe more friendly.

It works in go1.5.

@coveralls
Copy link

coveralls commented Jul 18, 2017

Coverage Status

Coverage remained the same at 82.129% when pulling b2b9069 on WindomZ:master into 3e619b6 on graphql-go:master.

@chris-ramon
Copy link
Member

lgtm, good catch!, thanks a lot @WindomZ 👍

@chris-ramon chris-ramon merged commit 096f5bc into graphql-go:master Jul 18, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants