1
0

qt receive tab: fix creating new payreq with all used imported wallet

fixes #6325
This commit is contained in:
SomberNight
2020-07-03 20:12:52 +02:00
parent 0f6898ed90
commit c54b9a6874
2 changed files with 18 additions and 12 deletions

View File

@@ -1123,7 +1123,7 @@ class LNWallet(LNWorker):
route[-1].node_features |= invoice_features
return route
def add_request(self, amount_sat, message, expiry):
def add_request(self, amount_sat, message, expiry) -> str:
coro = self._add_request_coro(amount_sat, message, expiry)
fut = asyncio.run_coroutine_threadsafe(coro, self.network.asyncio_loop)
try:
@@ -1158,7 +1158,7 @@ class LNWallet(LNWorker):
self.save_payment_info(info)
return lnaddr, invoice
async def _add_request_coro(self, amount_sat: Optional[int], message, expiry: int):
async def _add_request_coro(self, amount_sat: Optional[int], message, expiry: int) -> str:
lnaddr, invoice = await self.create_invoice(amount_sat, message, expiry)
key = bh2u(lnaddr.paymenthash)
req = LNInvoice.from_bech32(invoice)