btcpayserver/BTCPayServer/Extensions/StoreExtensions.cs
Nicolas Dorier 300d84c5d8
[UX/UI] Add CPFP (#3395)
* Add CPFP

* Sign PSBT should go back to the initial page
2022-02-10 12:24:28 +09:00

18 lines
620 B
C#

using System.Linq;
using BTCPayServer.Data;
namespace BTCPayServer
{
public static class StoreExtensions
{
public static DerivationSchemeSettings GetDerivationSchemeSettings(this StoreData store, BTCPayNetworkProvider networkProvider, string cryptoCode)
{
var paymentMethod = store
.GetSupportedPaymentMethods(networkProvider)
.OfType<DerivationSchemeSettings>()
.FirstOrDefault(p => p.PaymentId.PaymentType == Payments.PaymentTypes.BTCLike && p.PaymentId.CryptoCode == cryptoCode);
return paymentMethod;
}
}
}