mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2025-12-18 14:34:23 +01:00
Improve public LN node info (#2876)
* Add store name to LN info unavailable pae * Display multiple node info items if available Allows to view clearnet and Tor connection info side by side. * Re-add preferOnion for certain cases * HTML compatible node ids * Display more node connection failure details * Fix syntax error * Update BTCPayServer/Payments/Lightning/LightningLikePaymentHandler.cs Co-authored-by: Nicolas Dorier <nicolas.dorier@gmail.com> * View updates * Revert previous variable change * Keep logic out of the view Co-authored-by: Nicolas Dorier <nicolas.dorier@gmail.com>
This commit is contained in:
@@ -109,13 +109,13 @@ namespace BTCPayServer.Controllers
|
||||
var handler = _ServiceProvider.GetRequiredService<LightningLikePaymentHandler>();
|
||||
try
|
||||
{
|
||||
var info = await handler.GetNodeInfo(Request.IsOnion(), paymentMethod, network);
|
||||
var info = await handler.GetNodeInfo(paymentMethod, network, Request.IsOnion());
|
||||
if (!vm.SkipPortTest)
|
||||
{
|
||||
using var cts = new CancellationTokenSource(TimeSpan.FromSeconds(20));
|
||||
await handler.TestConnection(info, cts.Token);
|
||||
await handler.TestConnection(info.First(), cts.Token);
|
||||
}
|
||||
TempData[WellKnownTempData.SuccessMessage] = $"Connection to the Lightning node successful. Your node address: {info}";
|
||||
TempData[WellKnownTempData.SuccessMessage] = $"Connection to the Lightning node successful. Your node address: {info.First()}";
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user