From d5c44f8c728243edd8ade9273a9b4f6fb0aaeba4 Mon Sep 17 00:00:00 2001 From: Mirko Da Corte Date: Mon, 10 Jun 2024 04:20:56 +0200 Subject: [PATCH] minor --- src/BeeNet/BeeClient.cs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/BeeNet/BeeClient.cs b/src/BeeNet/BeeClient.cs index 58c9ea0..86b10fa 100644 --- a/src/BeeNet/BeeClient.cs +++ b/src/BeeNet/BeeClient.cs @@ -18,13 +18,13 @@ using System; using System.Collections.Generic; using System.Diagnostics.CodeAnalysis; -using System.Globalization; using System.IO; using System.Linq; using System.Net.Http; using System.Text.RegularExpressions; using System.Threading; using System.Threading.Tasks; +using FileResponse = Etherna.BeeNet.Models.FileResponse; namespace Etherna.BeeNet { @@ -44,12 +44,12 @@ public class BeeClient : IBeeClient, IDisposable public BeeClient( string baseUrl = "http://localhost/", int gatewayApiPort = 1633, - HttpClient? customHttpClient = null) + HttpClient? httpClient = null) { - httpClient = customHttpClient ?? new HttpClient { Timeout = DefaultTimeout }; + this.httpClient = httpClient ?? new HttpClient { Timeout = DefaultTimeout }; GatewayApiUrl = new Uri(BuildBaseUrl(baseUrl, gatewayApiPort)); - generatedClient = new BeeGeneratedClient(httpClient) { BaseUrl = GatewayApiUrl.ToString() }; + generatedClient = new BeeGeneratedClient(this.httpClient) { BaseUrl = GatewayApiUrl.ToString() }; } // Dispose. @@ -320,7 +320,7 @@ public async Task GetFeedAsync( CancellationToken cancellationToken = default) => (await generatedClient.FeedsGetAsync(owner, topic, at, after, type, cancellationToken).ConfigureAwait(false)).Reference; - public async Task GetFileAsync( + public async Task GetFileAsync( SwarmAddress address, bool? swarmCache = null, RedundancyStrategy? swarmRedundancyStrategy = null, @@ -338,7 +338,7 @@ public async Task GetFeedAsync( public Task GetFileHeadAsync(SwarmAddress address, CancellationToken cancellationToken = default) => generatedClient.BzzHeadAsync((string)address, cancellationToken); - public async Task GetFileWithPathAsync( + public async Task GetFileWithPathAsync( SwarmAddress address, string path, RedundancyStrategy? swarmRedundancyStrategy = null,