Remove obsolete errors

This commit is contained in:
nicolas.dorier 2024-08-29 10:47:03 +09:00
parent 588b00de45
commit 85cc221d50
No known key found for this signature in database
GPG Key ID: 6618763EF09186FE
2 changed files with 1 additions and 11 deletions

View File

@ -34,11 +34,6 @@ namespace BTCPayServer
Logs logs) Logs logs)
{ {
var networksList = networks.ToList(); var networksList = networks.ToList();
#if !ALTCOINS
var onlyBTC = networksList.Count == 1 && networksList.First().IsBTC;
if (!onlyBTC)
throw new ConfigException($"This build of BTCPay Server does not support altcoins. Configured networks: {string.Join(',', networksList.Select(n => n.CryptoCode).ToArray())}");
#endif
_NBXplorerNetworkProvider = nbxplorerNetworkProvider; _NBXplorerNetworkProvider = nbxplorerNetworkProvider;
NetworkType = nbxplorerNetworkProvider.NetworkType; NetworkType = nbxplorerNetworkProvider.NetworkType;
foreach (var network in networksList) foreach (var network in networksList)

View File

@ -12,17 +12,12 @@ namespace BTCPayServer
{ {
HashSet<string> chains = new HashSet<string>(StringComparer.OrdinalIgnoreCase); HashSet<string> chains = new HashSet<string>(StringComparer.OrdinalIgnoreCase);
bool all = false; bool all = false;
public SelectedChains(IConfiguration configuration, Logs logs) public SelectedChains(IConfiguration configuration)
{ {
foreach (var chain in (configuration["chains"] ?? "btc") foreach (var chain in (configuration["chains"] ?? "btc")
.Split(',', StringSplitOptions.RemoveEmptyEntries) .Split(',', StringSplitOptions.RemoveEmptyEntries)
.Select(t => t.ToUpperInvariant())) .Select(t => t.ToUpperInvariant()))
{ {
if (new[] { "ETH", "USDT20", "FAU" }.Contains(chain, StringComparer.OrdinalIgnoreCase))
{
logs.Configuration.LogWarning($"'{chain}' is not anymore supported, please remove it from 'chains'");
continue;
}
if (chain == "*") if (chain == "*")
{ {
all = true; all = true;