Merge pull request #7465 from bitromortac/2108-fix-7457-ln-payments
fix ln payments: set payto_e ln invoice correctly
This commit is contained in:
@@ -1970,7 +1970,6 @@ class ElectrumWindow(QMainWindow, MessageBoxMixin, Logger):
|
|||||||
self.show_error(_("Error parsing Lightning invoice") + f":\n{e}")
|
self.show_error(_("Error parsing Lightning invoice") + f":\n{e}")
|
||||||
return
|
return
|
||||||
|
|
||||||
self.payto_e.lightning_invoice = invoice
|
|
||||||
pubkey = bh2u(lnaddr.pubkey.serialize())
|
pubkey = bh2u(lnaddr.pubkey.serialize())
|
||||||
for k,v in lnaddr.tags:
|
for k,v in lnaddr.tags:
|
||||||
if k == 'd':
|
if k == 'd':
|
||||||
@@ -1980,6 +1979,7 @@ class ElectrumWindow(QMainWindow, MessageBoxMixin, Logger):
|
|||||||
description = ''
|
description = ''
|
||||||
self.payto_e.setFrozen(True)
|
self.payto_e.setFrozen(True)
|
||||||
self.payto_e.setText(pubkey)
|
self.payto_e.setText(pubkey)
|
||||||
|
self.payto_e.lightning_invoice = invoice
|
||||||
self.message_e.setText(description)
|
self.message_e.setText(description)
|
||||||
if lnaddr.get_amount_sat() is not None:
|
if lnaddr.get_amount_sat() is not None:
|
||||||
self.amount_e.setAmount(lnaddr.get_amount_sat())
|
self.amount_e.setAmount(lnaddr.get_amount_sat())
|
||||||
|
|||||||
Reference in New Issue
Block a user