mirror of
https://github.com/aljazceru/nutshell.git
synced 2025-12-23 03:34:19 +01:00
Multinut LND (#492)
* amount in melt request * apply fee limit * more error handling * wip: signal flag in /info * clean up multinut * decode mypy error lndrest * fix test * fix tests * signal feature and blindmessages_deprecated * setting * fix blindedsignature method * fix tests * mint info file * test mpp with lnd regtest * nuts optionsl mint info * try to enable mpp with lnd * test mpp with third payment
This commit is contained in:
@@ -6,7 +6,7 @@ from bolt11 import (
|
||||
decode,
|
||||
)
|
||||
|
||||
from ..core.base import Amount, MeltQuote, Unit
|
||||
from ..core.base import Amount, MeltQuote, PostMeltQuoteRequest, Unit
|
||||
from ..core.helpers import fee_reserve
|
||||
from ..core.settings import settings
|
||||
from .base import (
|
||||
@@ -167,8 +167,10 @@ class LNbitsWallet(LightningBackend):
|
||||
preimage=data["preimage"],
|
||||
)
|
||||
|
||||
async def get_payment_quote(self, bolt11: str) -> PaymentQuoteResponse:
|
||||
invoice_obj = decode(bolt11)
|
||||
async def get_payment_quote(
|
||||
self, melt_quote: PostMeltQuoteRequest
|
||||
) -> PaymentQuoteResponse:
|
||||
invoice_obj = decode(melt_quote.request)
|
||||
assert invoice_obj.amount_msat, "invoice has no amount."
|
||||
amount_msat = int(invoice_obj.amount_msat)
|
||||
fees_msat = fee_reserve(amount_msat)
|
||||
|
||||
Reference in New Issue
Block a user