FIELD_DEFINITION directive return nil obj
- Lingua principale
- Go
- Stelle
- 10.8k
- Fork
- 1.3k
- Merge medio
- 2g 36m
- PR unite (30g)
- 26
Descrizione
### What happened?
- FIELD_DEFINITION directive return nil obj
### What did you expect?
- return arguments
```graphql
directive @hello(reason: String = "No longer supported") on FIELD_DEFINITION
extend type Query {
test(hello: String!, world: String!): String! @hello
}
```
```go
config := gqlgen.Config{
Resolvers: &Resolver{service},
}
config.Directives.Hello = func(ctx context.Context, obj interface{}, next graphql.Resolver, reason *string) (res interface{}, err error) {
fmt.Printf("Obj %+v\n", obj)
return next(ctx)
}
```
output: nil
### versions
- `go run github.com/99designs/gqlgen version`: v0.17.36
- `go version`: v1.20.6
Guida per i contributori
Apri la guida per i contributori
Valutazione
Questa issue non è ancora stata valutata.