MCPcopy Create free account
hub / github.com/encoder-run/operator / _Query_storages

Method _Query_storages

pkg/graph/generated.go:3204–3233  ·  view source on GitHub ↗
(ctx context.Context, field graphql.CollectedField)

Source from the content-addressed store, hash-verified

3202}
3203
3204func (ec *executionContext) _Query_storages(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
3205 fc, err := ec.fieldContext_Query_storages(ctx, field)
3206 if err != nil {
3207 return graphql.Null
3208 }
3209 ctx = graphql.WithFieldContext(ctx, fc)
3210 defer func() {
3211 if r := recover(); r != nil {
3212 ec.Error(ctx, ec.Recover(ctx, r))
3213 ret = graphql.Null
3214 }
3215 }()
3216 resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
3217 ctx = rctx // use context from middleware stack in children
3218 return ec.resolvers.Query().Storages(rctx)
3219 })
3220 if err != nil {
3221 ec.Error(ctx, err)
3222 return graphql.Null
3223 }
3224 if resTmp == nil {
3225 if !graphql.HasFieldError(ctx, fc) {
3226 ec.Errorf(ctx, "must not be null")
3227 }
3228 return graphql.Null
3229 }
3230 res := resTmp.([]*model.Storage)
3231 fc.Result = res
3232 return ec.marshalNStorage2ᚕᚖgithubᚗcomᚋencoderᚑrunᚋoperatorᚋpkgᚋgraphᚋmodelᚐStorageᚄ(ctx, field.Selections, res)
3233}
3234
3235func (ec *executionContext) fieldContext_Query_storages(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
3236 fc = &graphql.FieldContext{

Callers 1

_QueryMethod · 0.95

Tested by

no test coverage detected