internal static IFilterOperationFieldDescriptor ID(
        this IFilterOperationFieldDescriptor descriptor)
    {
        if (descriptor is null)
        {
            throw new ArgumentNullException(nameof(descriptor));
        }

        descriptor
        .Extend()
        .OnBeforeCompletion((c, d) =>
        {
            d.Formatters.Push(CreateSerializer(c));
        });

        return(descriptor);
    }
Example #2
0
 public static void MakeNullable(this IFilterOperationFieldDescriptor descriptor) =>
 descriptor.Extend().OnBeforeCreate(
     (c, def) => def.Type = RewriteTypeToNullableType(def, c.TypeInspector));