Make `Config` not depend on `TorMonitor`
MODIFY
WalletWasabi.Fluent/Config.cs
WalletWasabi.Fluent/Config.cs
@@ -119,11 +119,6 @@ public class Config : ConfigBase
public Uri GetCurrentBackendUri()
{
- if (TorMonitor.RequestFallbackAddressUsage)
- {
- return GetFallbackBackendUri();
- }
-
if (_backendUri is { })
{
return _backendUri;

MODIFY
WalletWasabi.Fluent/Global.cs
WalletWasabi.Fluent/Global.cs
@@ -88,7 +88,10 @@ public class Global
if (Config.UseTor)
{
- HttpClientFactory = new HttpClientFactory(TorSettings.SocksEndpoint, backendUriGetter: () => Config.GetCurrentBackendUri());
+ HttpClientFactory = new HttpClientFactory(TorSettings.SocksEndpoint, backendUriGetter: () =>
+ {
+ return TorMonitor.RequestFallbackAddressUsage ? Config.GetFallbackBackendUri() : Config.GetCurrentBackendUri();
+ });
}
else
{

Make `Config` not depend on `TorMonitor`