aboutsummaryrefslogtreecommitdiffstats
path: root/api/graphql/graph/bug.generated.go
diff options
context:
space:
mode:
authorMichael Muré <batolettre@gmail.com>2023-08-12 14:05:02 +0200
committerGitHub <noreply@github.com>2023-08-12 14:05:02 +0200
commit20e62977a0509e2c79ef5d8d9173103a278b78ff (patch)
tree9a39ab11d0373caeaf34f2d06188c481d27f67d7 /api/graphql/graph/bug.generated.go
parenta0d225ce23af9f5dbe31521f19485c66d409e573 (diff)
parent429b913dc5519babfab47bf65222e32415a6c1bd (diff)
downloadgit-bug-20e62977a0509e2c79ef5d8d9173103a278b78ff.tar.gz
Merge pull request #1088 from MichaelMure/dependabot/go_modules/github.com/99designs/gqlgen-0.17.36
build(deps): bump github.com/99designs/gqlgen from 0.17.20 to 0.17.36
Diffstat (limited to 'api/graphql/graph/bug.generated.go')
-rw-r--r--api/graphql/graph/bug.generated.go416
1 files changed, 290 insertions, 126 deletions
diff --git a/api/graphql/graph/bug.generated.go b/api/graphql/graph/bug.generated.go
index ab9c6c34..a5685942 100644
--- a/api/graphql/graph/bug.generated.go
+++ b/api/graphql/graph/bug.generated.go
@@ -694,7 +694,7 @@ func (ec *executionContext) fieldContext_Bug_actors(ctx context.Context, field g
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Bug_actors_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
- return
+ return fc, err
}
return fc, nil
}
@@ -759,7 +759,7 @@ func (ec *executionContext) fieldContext_Bug_participants(ctx context.Context, f
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Bug_participants_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
- return
+ return fc, err
}
return fc, nil
}
@@ -824,7 +824,7 @@ func (ec *executionContext) fieldContext_Bug_comments(ctx context.Context, field
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Bug_comments_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
- return
+ return fc, err
}
return fc, nil
}
@@ -889,7 +889,7 @@ func (ec *executionContext) fieldContext_Bug_timeline(ctx context.Context, field
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Bug_timeline_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
- return
+ return fc, err
}
return fc, nil
}
@@ -954,7 +954,7 @@ func (ec *executionContext) fieldContext_Bug_operations(ctx context.Context, fie
ctx = graphql.WithFieldContext(ctx, fc)
if fc.Args, err = ec.field_Bug_operations_args(ctx, field.ArgumentMap(ec.Variables)); err != nil {
ec.Error(ctx, err)
- return
+ return fc, err
}
return fc, nil
}
@@ -1805,23 +1805,22 @@ var bugImplementors = []string{"Bug", "Authored"}
func (ec *executionContext) _Bug(ctx context.Context, sel ast.SelectionSet, obj models.BugWrapper) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, bugImplementors)
+
out := graphql.NewFieldSet(fields)
- var invalids uint32
+ deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("Bug")
case "id":
-
out.Values[i] = ec._Bug_id(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&out.Invalids, 1)
}
case "humanId":
field := field
- innerFunc := func(ctx context.Context) (res graphql.Marshaler) {
+ innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
@@ -1829,61 +1828,65 @@ func (ec *executionContext) _Bug(ctx context.Context, sel ast.SelectionSet, obj
}()
res = ec._Bug_humanId(ctx, field, obj)
if res == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
- out.Concurrently(i, func() graphql.Marshaler {
- return innerFunc(ctx)
+ if field.Deferrable != nil {
+ dfs, ok := deferred[field.Deferrable.Label]
+ di := 0
+ if ok {
+ dfs.AddField(field)
+ di = len(dfs.Values) - 1
+ } else {
+ dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
+ deferred[field.Deferrable.Label] = dfs
+ }
+ dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
+ return innerFunc(ctx, dfs)
+ })
- })
- case "status":
+ // don't run the out.Concurrently() call below
+ out.Values[i] = graphql.Null
+ continue
+ }
+ out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
+ case "status":
out.Values[i] = ec._Bug_status(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&out.Invalids, 1)
}
case "title":
-
out.Values[i] = ec._Bug_title(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&out.Invalids, 1)
}
case "labels":
-
out.Values[i] = ec._Bug_labels(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&out.Invalids, 1)
}
case "author":
-
out.Values[i] = ec._Bug_author(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&out.Invalids, 1)
}
case "createdAt":
-
out.Values[i] = ec._Bug_createdAt(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&out.Invalids, 1)
}
case "lastEdit":
-
out.Values[i] = ec._Bug_lastEdit(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&out.Invalids, 1)
}
case "actors":
field := field
- innerFunc := func(ctx context.Context) (res graphql.Marshaler) {
+ innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
@@ -1891,19 +1894,35 @@ func (ec *executionContext) _Bug(ctx context.Context, sel ast.SelectionSet, obj
}()
res = ec._Bug_actors(ctx, field, obj)
if res == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
- out.Concurrently(i, func() graphql.Marshaler {
- return innerFunc(ctx)
+ if field.Deferrable != nil {
+ dfs, ok := deferred[field.Deferrable.Label]
+ di := 0
+ if ok {
+ dfs.AddField(field)
+ di = len(dfs.Values) - 1
+ } else {
+ dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
+ deferred[field.Deferrable.Label] = dfs
+ }
+ dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
+ return innerFunc(ctx, dfs)
+ })
+
+ // don't run the out.Concurrently() call below
+ out.Values[i] = graphql.Null
+ continue
+ }
- })
+ out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "participants":
field := field
- innerFunc := func(ctx context.Context) (res graphql.Marshaler) {
+ innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
@@ -1911,19 +1930,35 @@ func (ec *executionContext) _Bug(ctx context.Context, sel ast.SelectionSet, obj
}()
res = ec._Bug_participants(ctx, field, obj)
if res == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
- out.Concurrently(i, func() graphql.Marshaler {
- return innerFunc(ctx)
+ if field.Deferrable != nil {
+ dfs, ok := deferred[field.Deferrable.Label]
+ di := 0
+ if ok {
+ dfs.AddField(field)
+ di = len(dfs.Values) - 1
+ } else {
+ dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
+ deferred[field.Deferrable.Label] = dfs
+ }
+ dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
+ return innerFunc(ctx, dfs)
+ })
+
+ // don't run the out.Concurrently() call below
+ out.Values[i] = graphql.Null
+ continue
+ }
- })
+ out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "comments":
field := field
- innerFunc := func(ctx context.Context) (res graphql.Marshaler) {
+ innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
@@ -1931,19 +1966,35 @@ func (ec *executionContext) _Bug(ctx context.Context, sel ast.SelectionSet, obj
}()
res = ec._Bug_comments(ctx, field, obj)
if res == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
- out.Concurrently(i, func() graphql.Marshaler {
- return innerFunc(ctx)
+ if field.Deferrable != nil {
+ dfs, ok := deferred[field.Deferrable.Label]
+ di := 0
+ if ok {
+ dfs.AddField(field)
+ di = len(dfs.Values) - 1
+ } else {
+ dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
+ deferred[field.Deferrable.Label] = dfs
+ }
+ dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
+ return innerFunc(ctx, dfs)
+ })
+
+ // don't run the out.Concurrently() call below
+ out.Values[i] = graphql.Null
+ continue
+ }
- })
+ out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "timeline":
field := field
- innerFunc := func(ctx context.Context) (res graphql.Marshaler) {
+ innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
@@ -1951,19 +2002,35 @@ func (ec *executionContext) _Bug(ctx context.Context, sel ast.SelectionSet, obj
}()
res = ec._Bug_timeline(ctx, field, obj)
if res == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
- out.Concurrently(i, func() graphql.Marshaler {
- return innerFunc(ctx)
+ if field.Deferrable != nil {
+ dfs, ok := deferred[field.Deferrable.Label]
+ di := 0
+ if ok {
+ dfs.AddField(field)
+ di = len(dfs.Values) - 1
+ } else {
+ dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
+ deferred[field.Deferrable.Label] = dfs
+ }
+ dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
+ return innerFunc(ctx, dfs)
+ })
+
+ // don't run the out.Concurrently() call below
+ out.Values[i] = graphql.Null
+ continue
+ }
- })
+ out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "operations":
field := field
- innerFunc := func(ctx context.Context) (res graphql.Marshaler) {
+ innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
@@ -1971,23 +2038,51 @@ func (ec *executionContext) _Bug(ctx context.Context, sel ast.SelectionSet, obj
}()
res = ec._Bug_operations(ctx, field, obj)
if res == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
- out.Concurrently(i, func() graphql.Marshaler {
- return innerFunc(ctx)
+ if field.Deferrable != nil {
+ dfs, ok := deferred[field.Deferrable.Label]
+ di := 0
+ if ok {
+ dfs.AddField(field)
+ di = len(dfs.Values) - 1
+ } else {
+ dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
+ deferred[field.Deferrable.Label] = dfs
+ }
+ dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
+ return innerFunc(ctx, dfs)
+ })
+
+ // don't run the out.Concurrently() call below
+ out.Values[i] = graphql.Null
+ continue
+ }
- })
+ out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
- out.Dispatch()
- if invalids > 0 {
+ out.Dispatch(ctx)
+ if out.Invalids > 0 {
return graphql.Null
}
+
+ atomic.AddInt32(&ec.deferred, int32(len(deferred)))
+
+ for label, dfs := range deferred {
+ ec.processDeferredGroup(graphql.DeferredGroup{
+ Label: label,
+ Path: graphql.GetPath(ctx),
+ FieldSet: dfs,
+ Context: ctx,
+ })
+ }
+
return out
}
@@ -1995,48 +2090,53 @@ var bugConnectionImplementors = []string{"BugConnection"}
func (ec *executionContext) _BugConnection(ctx context.Context, sel ast.SelectionSet, obj *models.BugConnection) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, bugConnectionImplementors)
+
out := graphql.NewFieldSet(fields)
- var invalids uint32
+ deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("BugConnection")
case "edges":
-
out.Values[i] = ec._BugConnection_edges(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- invalids++
+ out.Invalids++
}
case "nodes":
-
out.Values[i] = ec._BugConnection_nodes(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- invalids++
+ out.Invalids++
}
case "pageInfo":
-
out.Values[i] = ec._BugConnection_pageInfo(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- invalids++
+ out.Invalids++
}
case "totalCount":
-
out.Values[i] = ec._BugConnection_totalCount(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- invalids++
+ out.Invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
- out.Dispatch()
- if invalids > 0 {
+ out.Dispatch(ctx)
+ if out.Invalids > 0 {
return graphql.Null
}
+
+ atomic.AddInt32(&ec.deferred, int32(len(deferred)))
+
+ for label, dfs := range deferred {
+ ec.processDeferredGroup(graphql.DeferredGroup{
+ Label: label,
+ Path: graphql.GetPath(ctx),
+ FieldSet: dfs,
+ Context: ctx,
+ })
+ }
+
return out
}
@@ -2044,34 +2144,43 @@ var bugEdgeImplementors = []string{"BugEdge"}
func (ec *executionContext) _BugEdge(ctx context.Context, sel ast.SelectionSet, obj *models.BugEdge) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, bugEdgeImplementors)
+
out := graphql.NewFieldSet(fields)
- var invalids uint32
+ deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("BugEdge")
case "cursor":
-
out.Values[i] = ec._BugEdge_cursor(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- invalids++
+ out.Invalids++
}
case "node":
-
out.Values[i] = ec._BugEdge_node(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- invalids++
+ out.Invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
- out.Dispatch()
- if invalids > 0 {
+ out.Dispatch(ctx)
+ if out.Invalids > 0 {
return graphql.Null
}
+
+ atomic.AddInt32(&ec.deferred, int32(len(deferred)))
+
+ for label, dfs := range deferred {
+ ec.processDeferredGroup(graphql.DeferredGroup{
+ Label: label,
+ Path: graphql.GetPath(ctx),
+ FieldSet: dfs,
+ Context: ctx,
+ })
+ }
+
return out
}
@@ -2079,8 +2188,9 @@ var commentImplementors = []string{"Comment", "Authored"}
func (ec *executionContext) _Comment(ctx context.Context, sel ast.SelectionSet, obj *bug.Comment) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, commentImplementors)
+
out := graphql.NewFieldSet(fields)
- var invalids uint32
+ deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
@@ -2088,7 +2198,7 @@ func (ec *executionContext) _Comment(ctx context.Context, sel ast.SelectionSet,
case "id":
field := field
- innerFunc := func(ctx context.Context) (res graphql.Marshaler) {
+ innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
@@ -2096,19 +2206,35 @@ func (ec *executionContext) _Comment(ctx context.Context, sel ast.SelectionSet,
}()
res = ec._Comment_id(ctx, field, obj)
if res == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
- out.Concurrently(i, func() graphql.Marshaler {
- return innerFunc(ctx)
+ if field.Deferrable != nil {
+ dfs, ok := deferred[field.Deferrable.Label]
+ di := 0
+ if ok {
+ dfs.AddField(field)
+ di = len(dfs.Values) - 1
+ } else {
+ dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
+ deferred[field.Deferrable.Label] = dfs
+ }
+ dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
+ return innerFunc(ctx, dfs)
+ })
+
+ // don't run the out.Concurrently() call below
+ out.Values[i] = graphql.Null
+ continue
+ }
- })
+ out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
case "author":
field := field
- innerFunc := func(ctx context.Context) (res graphql.Marshaler) {
+ innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
@@ -2116,37 +2242,61 @@ func (ec *executionContext) _Comment(ctx context.Context, sel ast.SelectionSet,
}()
res = ec._Comment_author(ctx, field, obj)
if res == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&fs.Invalids, 1)
}
return res
}
- out.Concurrently(i, func() graphql.Marshaler {
- return innerFunc(ctx)
+ if field.Deferrable != nil {
+ dfs, ok := deferred[field.Deferrable.Label]
+ di := 0
+ if ok {
+ dfs.AddField(field)
+ di = len(dfs.Values) - 1
+ } else {
+ dfs = graphql.NewFieldSet([]graphql.CollectedField{field})
+ deferred[field.Deferrable.Label] = dfs
+ }
+ dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler {
+ return innerFunc(ctx, dfs)
+ })
- })
- case "message":
+ // don't run the out.Concurrently() call below
+ out.Values[i] = graphql.Null
+ continue
+ }
+ out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) })
+ case "message":
out.Values[i] = ec._Comment_message(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&out.Invalids, 1)
}
case "files":
-
out.Values[i] = ec._Comment_files(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
+ atomic.AddUint32(&out.Invalids, 1)
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
- out.Dispatch()
- if invalids > 0 {
+ out.Dispatch(ctx)
+ if out.Invalids > 0 {
return graphql.Null
}
+
+ atomic.AddInt32(&ec.deferred, int32(len(deferred)))
+
+ for label, dfs := range deferred {
+ ec.processDeferredGroup(graphql.DeferredGroup{
+ Label: label,
+ Path: graphql.GetPath(ctx),
+ FieldSet: dfs,
+ Context: ctx,
+ })
+ }
+
return out
}
@@ -2154,48 +2304,53 @@ var commentConnectionImplementors = []string{"CommentConnection"}
func (ec *executionContext) _CommentConnection(ctx context.Context, sel ast.SelectionSet, obj *models.CommentConnection) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, commentConnectionImplementors)
+
out := graphql.NewFieldSet(fields)
- var invalids uint32
+ deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("CommentConnection")
case "edges":
-
out.Values[i] = ec._CommentConnection_edges(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- invalids++
+ out.Invalids++
}
case "nodes":
-
out.Values[i] = ec._CommentConnection_nodes(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- invalids++
+ out.Invalids++
}
case "pageInfo":
-
out.Values[i] = ec._CommentConnection_pageInfo(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- invalids++
+ out.Invalids++
}
case "totalCount":
-
out.Values[i] = ec._CommentConnection_totalCount(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- invalids++
+ out.Invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
- out.Dispatch()
- if invalids > 0 {
+ out.Dispatch(ctx)
+ if out.Invalids > 0 {
return graphql.Null
}
+
+ atomic.AddInt32(&ec.deferred, int32(len(deferred)))
+
+ for label, dfs := range deferred {
+ ec.processDeferredGroup(graphql.DeferredGroup{
+ Label: label,
+ Path: graphql.GetPath(ctx),
+ FieldSet: dfs,
+ Context: ctx,
+ })
+ }
+
return out
}
@@ -2203,34 +2358,43 @@ var commentEdgeImplementors = []string{"CommentEdge"}
func (ec *executionContext) _CommentEdge(ctx context.Context, sel ast.SelectionSet, obj *models.CommentEdge) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, commentEdgeImplementors)
+
out := graphql.NewFieldSet(fields)
- var invalids uint32
+ deferred := make(map[string]*graphql.FieldSet)
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("CommentEdge")
case "cursor":
-
out.Values[i] = ec._CommentEdge_cursor(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- invalids++
+ out.Invalids++
}
case "node":
-
out.Values[i] = ec._CommentEdge_node(ctx, field, obj)
-
if out.Values[i] == graphql.Null {
- invalids++
+ out.Invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
- out.Dispatch()
- if invalids > 0 {
+ out.Dispatch(ctx)
+ if out.Invalids > 0 {
return graphql.Null
}
+
+ atomic.AddInt32(&ec.deferred, int32(len(deferred)))
+
+ for label, dfs := range deferred {
+ ec.processDeferredGroup(graphql.DeferredGroup{
+ Label: label,
+ Path: graphql.GetPath(ctx),
+ FieldSet: dfs,
+ Context: ctx,
+ })
+ }
+
return out
}