Right now the query and mutations methods on GQLCLient return an error type from shurcooL-graphql which does not match the concrete error type from the do methods. This causes unnecessary complexity when trying to do type assertion on the errors returned from the GQLCLient methods. To fix this we can wrap the errors returned from query and mutations methods in a GQLError.
Right now the
query
andmutations
methods onGQLCLient
return an error type from shurcooL-graphql which does not match the concrete error type from thedo
methods. This causes unnecessary complexity when trying to do type assertion on the errors returned from theGQLCLient
methods. To fix this we can wrap the errors returned fromquery
andmutations
methods in aGQLError
.