mirror of
https://github.com/lnbits/lnbits-legend.git
synced 2025-03-15 12:20:21 +01:00
fix: proper status check in invoice paid callback (#2592)
status fields like preimage and fee_msat are never updated otherwise
This commit is contained in:
parent
7298c4664b
commit
f9133760fc
1 changed files with 2 additions and 2 deletions
|
@ -175,7 +175,7 @@ async def check_pending_payments():
|
|||
|
||||
async def invoice_callback_dispatcher(checking_id: str):
|
||||
"""
|
||||
Takes incoming payments, sets pending=False, and dispatches them to
|
||||
Takes an incoming payment, checks its status, and dispatches it to
|
||||
invoice_listeners from core and extensions.
|
||||
"""
|
||||
payment = await get_standalone_payment(checking_id, incoming=True)
|
||||
|
@ -183,7 +183,7 @@ async def invoice_callback_dispatcher(checking_id: str):
|
|||
logger.trace(
|
||||
f"invoice listeners: sending invoice callback for payment {checking_id}"
|
||||
)
|
||||
await payment.set_pending(False)
|
||||
await payment.check_status()
|
||||
for name, send_chan in invoice_listeners.items():
|
||||
logger.trace(f"invoice listeners: sending to `{name}`")
|
||||
await send_chan.put(payment)
|
||||
|
|
Loading…
Add table
Reference in a new issue