aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/github.com/99designs/gqlgen/graphql/response.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/99designs/gqlgen/graphql/response.go')
-rw-r--r--vendor/github.com/99designs/gqlgen/graphql/response.go24
1 files changed, 0 insertions, 24 deletions
diff --git a/vendor/github.com/99designs/gqlgen/graphql/response.go b/vendor/github.com/99designs/gqlgen/graphql/response.go
deleted file mode 100644
index 6fe55d56..00000000
--- a/vendor/github.com/99designs/gqlgen/graphql/response.go
+++ /dev/null
@@ -1,24 +0,0 @@
-package graphql
-
-import (
- "context"
- "encoding/json"
- "fmt"
-
- "github.com/vektah/gqlparser/gqlerror"
-)
-
-// Errors are intentionally serialized first based on the advice in
-// https://github.com/facebook/graphql/commit/7b40390d48680b15cb93e02d46ac5eb249689876#diff-757cea6edf0288677a9eea4cfc801d87R107
-// and https://github.com/facebook/graphql/pull/384
-type Response struct {
- Errors gqlerror.List `json:"errors,omitempty"`
- Data json.RawMessage `json:"data"`
- Extensions map[string]interface{} `json:"extensions,omitempty"`
-}
-
-func ErrorResponse(ctx context.Context, messagef string, args ...interface{}) *Response {
- return &Response{
- Errors: gqlerror.List{{Message: fmt.Sprintf(messagef, args...)}},
- }
-}