Private field name fix

This commit is contained in:
Sergey Chebotar 2021-11-29 17:13:36 +03:00
parent 2afcbbf08c
commit e67b5b24fd

View File

@ -7,12 +7,12 @@ namespace Rehau.Sku.Assist
{
public class Functions
{
private static HttpClient httpClient = new HttpClient();
private static HttpClient _httpClient = new HttpClient();
[ExcelFunction]
public static async Task<string> RAUNAME(string request)
{
Task<string> contentTask = Task.Run(() => SkuAssist.GetContent(request, httpClient));
Task<string> contentTask = Task.Run(() => SkuAssist.GetContent(request, _httpClient));
Task<IDocument> documentTask = await contentTask.ContinueWith(content => SkuAssist.GetDocument(content));
IProduct product = await documentTask.ContinueWith(doc => SkuAssist.GetProductFromDocument(doc.Result));
return product == null ? ExcelError.ExcelErrorNull.ToString() : product.ToString();