Skip to content

Commit

Permalink
fixed error when unmarshalling directive locations in introspection r…
Browse files Browse the repository at this point in the history
…esponse
  • Loading branch information
AlecAivazis committed Jul 18, 2019
1 parent 78e82fe commit 21bf442
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion introspection.go
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,8 @@ func IntrospectAPI(queryer Queryer) (*ast.Schema, error) {
return nil, err
}

fmt.Println(directive.Locations)

// save the directive definition to the schema
schema.Directives[directive.Name] = &ast.DirectiveDefinition{
Name: directive.Name,
Expand Down Expand Up @@ -336,7 +338,7 @@ type IntrospectionQuerySchema struct {
type IntrospectionQueryDirective struct {
Name string `json:"name"`
Description string `json:"description"`
Locations []string `json:"location"`
Locations []string `json:"locations"`
Args []IntrospectionInputValue `json:"arg"`
}

Expand Down

0 comments on commit 21bf442

Please sign in to comment.