(ctx context.Context, field graphql.CollectedField, obj *model.Model)
| 1459 | } |
| 1460 | |
| 1461 | func (ec *executionContext) _Model_displayName(ctx context.Context, field graphql.CollectedField, obj *model.Model) (ret graphql.Marshaler) { |
| 1462 | fc, err := ec.fieldContext_Model_displayName(ctx, field) |
| 1463 | if err != nil { |
| 1464 | return graphql.Null |
| 1465 | } |
| 1466 | ctx = graphql.WithFieldContext(ctx, fc) |
| 1467 | defer func() { |
| 1468 | if r := recover(); r != nil { |
| 1469 | ec.Error(ctx, ec.Recover(ctx, r)) |
| 1470 | ret = graphql.Null |
| 1471 | } |
| 1472 | }() |
| 1473 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { |
| 1474 | ctx = rctx // use context from middleware stack in children |
| 1475 | return obj.DisplayName, nil |
| 1476 | }) |
| 1477 | if err != nil { |
| 1478 | ec.Error(ctx, err) |
| 1479 | return graphql.Null |
| 1480 | } |
| 1481 | if resTmp == nil { |
| 1482 | if !graphql.HasFieldError(ctx, fc) { |
| 1483 | ec.Errorf(ctx, "must not be null") |
| 1484 | } |
| 1485 | return graphql.Null |
| 1486 | } |
| 1487 | res := resTmp.(string) |
| 1488 | fc.Result = res |
| 1489 | return ec.marshalNString2string(ctx, field.Selections, res) |
| 1490 | } |
| 1491 | |
| 1492 | func (ec *executionContext) fieldContext_Model_displayName(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { |
| 1493 | fc = &graphql.FieldContext{ |
no test coverage detected