(ctx context.Context, field graphql.CollectedField)
| 2948 | } |
| 2949 | |
| 2950 | func (ec *executionContext) _Query_models(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { |
| 2951 | fc, err := ec.fieldContext_Query_models(ctx, field) |
| 2952 | if err != nil { |
| 2953 | return graphql.Null |
| 2954 | } |
| 2955 | ctx = graphql.WithFieldContext(ctx, fc) |
| 2956 | defer func() { |
| 2957 | if r := recover(); r != nil { |
| 2958 | ec.Error(ctx, ec.Recover(ctx, r)) |
| 2959 | ret = graphql.Null |
| 2960 | } |
| 2961 | }() |
| 2962 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { |
| 2963 | ctx = rctx // use context from middleware stack in children |
| 2964 | return ec.resolvers.Query().Models(rctx) |
| 2965 | }) |
| 2966 | if err != nil { |
| 2967 | ec.Error(ctx, err) |
| 2968 | return graphql.Null |
| 2969 | } |
| 2970 | if resTmp == nil { |
| 2971 | if !graphql.HasFieldError(ctx, fc) { |
| 2972 | ec.Errorf(ctx, "must not be null") |
| 2973 | } |
| 2974 | return graphql.Null |
| 2975 | } |
| 2976 | res := resTmp.([]*model.Model) |
| 2977 | fc.Result = res |
| 2978 | return ec.marshalNModel2ᚕᚖgithubᚗcomᚋencoderᚑrunᚋoperatorᚋpkgᚋgraphᚋmodelᚐModelᚄ(ctx, field.Selections, res) |
| 2979 | } |
| 2980 | |
| 2981 | func (ec *executionContext) fieldContext_Query_models(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { |
| 2982 | fc = &graphql.FieldContext{ |
no test coverage detected