bug: Generating Required Custom Type as Pointer
- Ngôn ngữ chính
- Go
- Star
- 10.8k
- Fork
- 1.3k
- Merge trung bình
- 2 ngày 36 phút
- Pull request đã merge (30 ngày)
- 26
Mô tả
### What happened?
When I define a custom type as required, it is generated as pointer. For example I have `[FavoriteList!]` in my schema but it generates resolver as `[]*model.FavoriteList`
### What did you expect?
I expect custom model type as not a pointer type, I think it should be `[]model.FavoriteList`
### Minimal graphql.schema and models to reproduce
```graphql
type FavoriteList {
id: Int
}
extend type Query {
favoriteLists: [FavoriteList!]
}
```
```go
func (r *queryResolver) FavoriteLists(ctx context.Context) ([]*model.FavoriteList, error) {
// ...
}
```
### versions
- `go run github.com/99designs/gqlgen version`? - v0.17.40
- `go version`? - 1.21.1
Hướng dẫn đóng góp
Đánh giá
Issue này chưa được đánh giá.