Add synchronous version of UpdateArticleAsync with XML documentation
This commit is contained in:
@@ -15,9 +15,19 @@ public static class PutExtensions
|
||||
/// <param name="article">The <see cref="Article"/> entity to be updated.</param>
|
||||
/// <param name="apiVersion">Optional API version to include in the request.</param>
|
||||
/// <returns>A <see cref="Task"/> representing the asynchronous operation.</returns>
|
||||
public static Task UpdateArticleAsync(this IMediator mediator, Article article, int? apiVersion = null) =>
|
||||
mediator.Send(new PutRequest(article)
|
||||
{
|
||||
ApiVersion = apiVersion
|
||||
});
|
||||
public static Task UpdateArticleAsync(this IMediator mediator, Article article, int? apiVersion = null) => mediator.Send(new PutRequest(article)
|
||||
{
|
||||
ApiVersion = apiVersion
|
||||
});
|
||||
|
||||
/// <summary>
|
||||
/// Sends a request to update an existing <see cref="Article"/> using MediatR.
|
||||
/// </summary>
|
||||
/// <param name="mediator">The <see cref="IMediator"/> instance used to send the request.</param>
|
||||
/// <param name="article">The <see cref="Article"/> entity to be updated.</param>
|
||||
/// <param name="apiVersion">Optional API version to include in the request.</param>
|
||||
public static void UpdateArticle(this IMediator mediator, Article article, int? apiVersion = null) => mediator.Send(new PutRequest(article)
|
||||
{
|
||||
ApiVersion = apiVersion
|
||||
}).GetAwaiter().GetResult();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user