graphql-client icon indicating copy to clipboard operation
graphql-client copied to clipboard

Correct error message when providing wrong type of query

Open esse opened this issue 6 years ago • 0 comments

GraphQL::Client is raising a TypeError when definition isn't a OperationDefinition. However, error message was using a definition.class.name as info what was provided - which was always equal to GraphQL::Language::Nodes::Document.

This commit fixes that and outputs real type of query provided in the error message.

esse avatar Nov 11 '19 17:11 esse