fix: fetch incoming payment (#35)

did not work for internal payment
This commit is contained in:
dni ⚡ 2024-09-03 16:35:42 +02:00 committed by GitHub
parent 400b39211d
commit 9ca714d878
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 3 deletions

View file

@ -1,7 +1,6 @@
import asyncio
from lnbits.core.models import Payment
from lnbits.helpers import get_current_extension_name
from lnbits.tasks import register_invoice_listener
from .crud import set_ticket_paid
@ -9,7 +8,7 @@ from .crud import set_ticket_paid
async def wait_for_paid_invoices():
invoice_queue = asyncio.Queue()
register_invoice_listener(invoice_queue, get_current_extension_name())
register_invoice_listener(invoice_queue, "ext_events")
while True:
payment = await invoice_queue.get()