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

Method _Repository_url

pkg/graph/generated.go:3943–3972  ·  view source on GitHub ↗
(ctx context.Context, field graphql.CollectedField, obj *model.Repository)

Source from the content-addressed store, hash-verified

3941}
3942
3943func (ec *executionContext) _Repository_url(ctx context.Context, field graphql.CollectedField, obj *model.Repository) (ret graphql.Marshaler) {
3944 fc, err := ec.fieldContext_Repository_url(ctx, field)
3945 if err != nil {
3946 return graphql.Null
3947 }
3948 ctx = graphql.WithFieldContext(ctx, fc)
3949 defer func() {
3950 if r := recover(); r != nil {
3951 ec.Error(ctx, ec.Recover(ctx, r))
3952 ret = graphql.Null
3953 }
3954 }()
3955 resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
3956 ctx = rctx // use context from middleware stack in children
3957 return obj.URL, nil
3958 })
3959 if err != nil {
3960 ec.Error(ctx, err)
3961 return graphql.Null
3962 }
3963 if resTmp == nil {
3964 if !graphql.HasFieldError(ctx, fc) {
3965 ec.Errorf(ctx, "must not be null")
3966 }
3967 return graphql.Null
3968 }
3969 res := resTmp.(string)
3970 fc.Result = res
3971 return ec.marshalNString2string(ctx, field.Selections, res)
3972}
3973
3974func (ec *executionContext) fieldContext_Repository_url(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) {
3975 fc = &graphql.FieldContext{

Callers 1

_RepositoryMethod · 0.95

Calls 2

marshalNString2stringMethod · 0.95

Tested by

no test coverage detected