Refactor how we handle and validate LN ConnectionStrings (#2314)

* Refactor how we handle and validate LN ConnectionStrings

* Migrate existing connection string to Internal Node if they are the same. Cleanup some obsolete fields

* Fix typos, remove duplicated method

* Add a InternalNodeRef to LightningSupportedPaymentMethod
This commit is contained in:
Nicolas Dorier
2021-03-02 11:11:58 +09:00
committed by GitHub
parent 49ae62b02e
commit 7e714f1ef8
24 changed files with 572 additions and 297 deletions

View File

@@ -546,8 +546,8 @@ namespace BTCPayServer.Controllers
vm.LightningNodes.Add(new StoreViewModel.LightningNode()
{
CryptoCode = paymentMethodId.CryptoCode,
Address = lightning?.GetLightningUrl()?.BaseUri.AbsoluteUri ?? string.Empty,
Enabled = !excludeFilters.Match(paymentMethodId) && lightning?.GetLightningUrl() != null
Address = lightning?.GetExternalLightningUrl()?.BaseUri.AbsoluteUri ?? "Internal node",
Enabled = !excludeFilters.Match(paymentMethodId)
});
break;
}