public static Task <SanityMutationResponse <TDoc> > CommitAsync <TDoc>(this SanityMutationBuilder <TDoc> transactionBuilder, bool returnIds = false, bool returnDocuments = true, SanityMutationVisibility visibility = SanityMutationVisibility.Sync, CancellationToken cancellationToken = default) { var result = transactionBuilder.InnerBuilder.Client.CommitMutationsAsync <TDoc>(transactionBuilder.Build(), returnIds, returnDocuments, visibility, cancellationToken); transactionBuilder.Clear(); return(result); }
public static Task <SanityMutationResponse> CommitAsync(this SanityMutationBuilder transactionBuilder, bool returnIds = false, bool returnDocuments = true, SanityMutationVisibility visibility = SanityMutationVisibility.Sync) { var result = transactionBuilder.Client.CommitMutationsAsync(transactionBuilder.Build(transactionBuilder.Client.SerializerSettings), returnIds, returnDocuments, visibility); transactionBuilder.Clear(); return(result); }