(_ context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int)
| 119 | } |
| 120 | |
| 121 | func (bugResolver) Actors(_ context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error) { |
| 122 | input := models.ConnectionInput{ |
| 123 | Before: before, |
| 124 | After: after, |
| 125 | First: first, |
| 126 | Last: last, |
| 127 | } |
| 128 | |
| 129 | edger := func(actor models.IdentityWrapper, offset int) connections.Edge { |
| 130 | return models.IdentityEdge{ |
| 131 | Node: actor, |
| 132 | Cursor: connections.OffsetToCursor(offset), |
| 133 | } |
| 134 | } |
| 135 | |
| 136 | conMaker := func(edges []*models.IdentityEdge, nodes []models.IdentityWrapper, info *models.PageInfo, totalCount int) (*models.IdentityConnection, error) { |
| 137 | return &models.IdentityConnection{ |
| 138 | Edges: edges, |
| 139 | Nodes: nodes, |
| 140 | PageInfo: info, |
| 141 | TotalCount: totalCount, |
| 142 | }, nil |
| 143 | } |
| 144 | |
| 145 | actors, err := obj.Actors() |
| 146 | if err != nil { |
| 147 | return nil, err |
| 148 | } |
| 149 | |
| 150 | return connections.Connection(actors, edger, conMaker, input) |
| 151 | } |
| 152 | |
| 153 | func (bugResolver) Participants(_ context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error) { |
| 154 | input := models.ConnectionInput{ |
nothing calls this directly
no test coverage detected